Created On: 12 December 2010
Problem:
Is it possible to remove a table from the catalog of AcuXDBC?
Resolution:
The best way to remove an existing table from the system catalog of AcuXDBC is using the tool "asql" located in the BIN directory of the AcuXDBC installation. This tool is a batch file that can have a .bat or a .sh extension, depending on the Operating System.
To start the tool, just use this command line:
C:\>asql
SQL (/? for help) ==>
A new prompt is shown. From here, it is possible to drop the table simply using this syntax:
SQL (/? for help) ==> drop table mytable;
If there are doubts about the name of the table, or about the owner of the table, just run this query:
SQL (/? for help) ==> select t_owner, t_name from genesis_tables where t_name='MYTABLE';
T_OWNER T_NAME
------------------------------ ------------------------------
MYADM MYTABLE
PUBLIC MYTABLE
In this example, two tables (aliases) are present, each one with a different owner.
To be sure to drop the correct table, use this syntax:
SQL (/? for help) ==> drop table MYADM.MYTABLE;
To start the tool, just use this command line:
C:\>asql
SQL (/? for help) ==>
A new prompt is shown. From here, it is possible to drop the table simply using this syntax:
SQL (/? for help) ==> drop table mytable;
If there are doubts about the name of the table, or about the owner of the table, just run this query:
SQL (/? for help) ==> select t_owner, t_name from genesis_tables where t_name='MYTABLE';
T_OWNER T_NAME
------------------------------ ------------------------------
MYADM MYTABLE
PUBLIC MYTABLE
In this example, two tables (aliases) are present, each one with a different owner.
To be sure to drop the correct table, use this syntax:
SQL (/? for help) ==> drop table MYADM.MYTABLE;
Incident #2487474