Oracle proxy user with Spring

The standard solution to manage the database connections in a web application is to let the server manage it, and use Spring to inject it wherever it is needed. By doing so, we can let also the transaction management to be done by a third party API, Spring fits perfectly this need. But this option… Continue reading Oracle proxy user with Spring

Enable transactions on Informix DB

We need to have the following variables set: INFORMIXDIR=/opt/IBM/informix INFORMIXSQLHOSTS=/opt/IBM/Informix/etc/sqlhosts.ol_informix1170 INFORMIXSERVER=ol_informix1170 Now, we can enable the transactions, in first we need to put the database in “quiescent mode” (???): >/opt/IBM/informix/bin/onmode –uy Note: doing this disable access to the database. enable transactions: >/opt/IBM/informix/bin/ontape –s –L 0 –B d9exp Re-enable the connections: >/opt/IBM/informix/bin/onmode -m Helpful information: Jdbc… Continue reading Enable transactions on Informix DB

Unlock Informix table

First, get the sessid using the following sql: select unique dbsname db, tabname table, case when type=”S” then “shared lock” when type=”IS” then “intent shared lock” when type=”SIX” then “shared intent excl lock” when type=”XS” then “shared key value by RR” when type=”IX” then “intent excl lock” when type=”X” then “exclusive lock” when type=”XR” then… Continue reading Unlock Informix table

Kill Oracle sessions

Some time the Oracle connections stay open, blocking the other transactions, there’s no other option than kill it. We firstly need to identify it, as system user, execute the following query: SELECT s.inst_id, s.sid, s.serial#, p.spid, s.username, s.program FROM gv$session s JOIN gv$process p ON p.addr = s.paddr AND p.inst_id = s.inst_id WHERE s.type !=… Continue reading Kill Oracle sessions

Published
Categorized as SQL Tagged ,