Mercurial > hg > ltpda
view m-toolbox/classes/tests/database/@ltpda_database/getDataIdFromAoTable.m @ 1:2014ba5b353a database-connection-manager
Remove old code
author | Daniele Nicolodi <nicolodi@science.unitn.it> |
---|---|
date | Sat, 03 Dec 2011 18:13:55 +0100 |
parents | f0afece42f48 |
children | 79dc7091dbbc |
line wrap: on
line source
% % DESCRIPTION: Returns the data ID (different only in a old databases) for % the given object ID % % VERSION: $Id: getDataIdFromAoTable.m,v 1.1 2011/05/25 16:23:53 ingo Exp $ % function val = getDataIdFromAoTable(utp, objID) utp.conn.setLocked(true); utp.conn.openConnection(); c = utp.conn.getConn(); q = sprintf('SELECT data_id FROM ao WHERE ao.obj_id=%d', objID); try val = utils.jmysql.execute(c, q); catch Me utp.conn.setLocked(false); utp.conn.closeConnection(); rethrow(Me); end utp.conn.setLocked(false); utp.conn.closeConnection(); end