Subject | Drop Table problem |
---|---|
Author | bmckenna6 |
Post date | 2005-06-15T05:09:25Z |
I'm a bit new to dropping tables, and I thought I had it solved
but apparently not:
I'm using v1.00796, single W2K/sp4 system
I'm getting
ISC ERROR CODE: 335544348
No current record for fetch operation
unsuccessful metadata update { there are no dependencies }
object MYTABLE is in use
from the following:
qryDropTable.Close;
qryDropTable.SQL.Clear;
qryDropTable.SQL.Add('DELETE FROM MYTABLE');
qryDropTable.ExecSQL;
qryDropTable.Close;
// adding a separate Connection and closing/opening seemed to
// solve the issue for a while. Is it true that closing/opening
// the Connection is recommended for dropping tables?
connect2.Connected := False;
connect2.Connected := True;
qryDropTable.SQL.Clear;
qryDropTable.SQL.Add('DROP TABLE MYTABLE');
qryDropTable.ExecSQL;
It seems that if the table is empty/newly created,
then no error. Now, the error only seems to occur
after there are actual records that get deleted from the
first statements.
Could this have anything to do with indexes?
Do they have to be dropped first/separately?
but apparently not:
I'm using v1.00796, single W2K/sp4 system
I'm getting
ISC ERROR CODE: 335544348
No current record for fetch operation
unsuccessful metadata update { there are no dependencies }
object MYTABLE is in use
from the following:
qryDropTable.Close;
qryDropTable.SQL.Clear;
qryDropTable.SQL.Add('DELETE FROM MYTABLE');
qryDropTable.ExecSQL;
qryDropTable.Close;
// adding a separate Connection and closing/opening seemed to
// solve the issue for a while. Is it true that closing/opening
// the Connection is recommended for dropping tables?
connect2.Connected := False;
connect2.Connected := True;
qryDropTable.SQL.Clear;
qryDropTable.SQL.Add('DROP TABLE MYTABLE');
qryDropTable.ExecSQL;
It seems that if the table is empty/newly created,
then no error. Now, the error only seems to occur
after there are actual records that get deleted from the
first statements.
Could this have anything to do with indexes?
Do they have to be dropped first/separately?