[TYPO3-dev] Is a lock tables possible with TYPO3
Søren Schaffstein
soeren.schaffstein at media-lights.de
Thu Jun 1 20:05:14 CEST 2006
Hi there,
I am trying to lock a table in one of my extensions to write the correct
data. I'm trying to use the typo3 DB functions but this doesn't seem to
work. The table will be locked but I cannot access it then...
$GLOBALS['TYPO3_DB']->sql_query('LOCK TABLES tablex READ');
//get data from table
$Query = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
'rank',
'tablex'
);
//...
//...process data from table
//...
//write result back to table
$GLOBALS['TYPO3_DB']->exec_INSERTquery(
'tablex',
array(
'rank' => $result,
)
);
$GLOBALS['TYPO3_DB']->sql_query('UNLOCK TABLES');
Is it possible to lock and unlock tables with TYPO3 and still work with
them? If yes how should I do it?
Thanks,
Søren
More information about the TYPO3-dev
mailing list