Re: How to check for a locked table
Posted in 1996
> "F. Javier Zarazaga" <zarazaga@ebro.cps.unizar.es> writes: > I want to check if a table is locked using SQL with informix SE, but I > don't know how to do it. > Could anyone help me? You try to lock the table. If it failed it was allready locked, otherwise not. Sadly there is no peek_lock function or similar. > And, do anyone know how to check the lock mode of the database? I don't remember of any "lock modes" in the SE engine. Do you mean it the locking of a table (or the whole database) where done in shared or exclusive mode by some other program? In that case if you gain access to the database at all it isn't locked. If you can select from a table, but not update it, it's locked in shared mode. If you can't select from it it's locked in exclusive mode. This is all in SE. OnLine strangely behave differently. Nils.Myklebust@ccmail.telemax.no NM Data AS, Postbox 9090, Gronland, 0133 Oslo, Norway My opinions are those of my company