drupaldrupal-nodesdrupal-database

Does Drupal node_load lock the Node and Related Fields?


I'm in Drupal 7 and implementing custom script inside Drupal Root folder. Then i'm trying to call-up a node with node_load(1234) and then node_save($node). Between this two methods, i'm trying to DELETE some records (some DB Rows). But i can not make it work in any way i found.

The scenario is like:

$node = node_load($nid);
..
.. Step 1. Some node updates like: $node->title = "New Title!";
.. Step 2. Some row DELETIONS
..
node_save($node);

Then Step 2. is NOT WORKING.
Step 2. may include Row Deletion Methods like:

$deleted_row = db_delete('some_table')
          ->condition('nid', $nid)
          ->execute();
[or]
db_query("DELETE FROM {some_table} WHERE nid = %d", $nid);

So my questions are:

Any suggestion please.


Solution

  • No one answered. But i found it by myself that the answer is "no, it doesn't lock".