Re: Table cannot be dropped (314)
Posted in 1995
Topics: Installation, Setup & Upgrades, Error Codes & Troubleshooting, Connectivity: ESQL/C, 4GL & Embedded SQL
In <4887@targon.UUCP> Herman Nienhuis <hnienhuis.via@sni.de> wrote:
>Hello,
>
>We have written a software installation tool using ESQL/C. This
>software uses a table to control the process of altering some
>of the existing tables. At the end of the installation this table
>has to be dropped. At that moment the installation tool is the
>ONLY database user, without any running transactions.
>
>When we try to drop the table we get DB error 314 "table in use",
>ISAM error 0. How can the table be in use if there are no other>users?
>
>We are running Informix Online 5.0, the database is in ANSI MODE.
>
>Any help would be appreciated.
>
>Herman Nienhuis.
---------------------------------------------------------------------------
Try this :
1) Delete from table "syscolumns" rows, which contains columns of break table:
delete from syscolumns where tabid =
(select tabid from systables where tabname = "nameofyourtable")
2) Delete from table "systables" rows, which contains break table:
delete from systables where tabname = "nameofyourtable"
If something wrong, then try do conversely:
1) Note "tabid" of break table:
select tabid from from systables where tabname = "nameofyourtable" ;
2) Old clause 2
3) Old clause 1:
delete from syscolumns where tabid = tabidofyourtable
If Informix will be swear, try do:
tbmode -k
tbinit
The same can or may do from "sperform" or "isql" through form
(at first need be generate form for "systables" and "syscolumns" tables)
I can't guarantee, that this absolute clear method, but i use it.
Gennady. Institute of nuclear research, Kiev, Ukraine.
E-mail : gena@oubaes.freenet.kiev.ua
P.S. Sorry for my english.