DB2 REORG fails on 3.5.0
A Java SQL client for any JDBC compliant database
Brought to you by:
colbell,
gerdwagner
SQuirrel version 3.5.0. Cannot execute reorg table command for DB2.
The query "reorg table schema.table" returns
An unexpected token "schemaname" was found following "reorg table ". Expected tokens may include: "JOIN". SQL Code: -104, SQL State: 42601
The query "reorg table table" returns
An unexpected token "table" was found following "reorg ". Expected tokens may include: "JOIN <joined_table>". SQL Code: -104, SQL State: 42601</joined_table>
When it's a reorg query, SQuirrel had to call SYSPROC.ADMIN_CMD('reorg table schema.table'). That'll do the work
Try this:
CALL SYSPROC.ADMIN_CMD ('REORG TABLE table_name')