Hi, Folks:
I meet some problem that I always get the exception
"informix.api.DBServerException: XIX000:-106:ISAM error: non-exclusive
access."
when I try to drop the table. I believe what I do is really simple, but I
really can't find where is my problem at all. Does anyone know where the
problem is? The problem is described briefly as follows:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Everthing work fine except that if I select data from table
and then drop it. The error message "non-exclusive" will apear,
and the table still exist.... And so I guess the problem comes from
select part,but I have no idea about it.....
//IDE: VisualCafe 4
//LANGUAGE: Java
//connecton method
import informix.api.*;
import informix.api.remote.rmi.*;
Connection conn;
Query query;
Credentials cred;
try{
cred = new RMICredentials(appServer, db, user, sys, passwd);
conn = cred.connection();
query = conn.query();
}catch (Exception exec){;}
try{
conn.open();
}catch (Exception exec){;}
.
. creat table e and insert data into it
.
<!-- the problem may come from the below code -->
// retireve data from table
Row row;
String select_qry = new String("select img_id from e;");
try{
if (!query.execForIteration(select_qry))
System.out.println("Could not excute select_from_temp_qry!");
while ((row = query.nextRow()) != null)
{
;
}
}
catch (DBException dbexc){;}
<!-- end -->
.
. delete table e
.
// drop table
String Drop_qry = new String("DROP TABLE e;");
try{
if (!query.execForStatus(Drop_qry))
;
}catch (DBException dbexc){;}
<!-- when executing droping table e, the error message will appear -->
thanks a lot!
Joe