On 2 October 2012 19:57, Earnie Boyd <span dir="ltr"><<a href="mailto:earnie@users.sourceforge.net" target="_blank">earnie@users.sourceforge.net</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On Tue, Oct 2, 2012 at 2:23 PM, Wipe_Out <<a href="mailto:wipe_out@users.sourceforge.net">wipe_out@users.sourceforge.net</a>> wrote:<br>
> On 2 October 2012 17:59, Michael Prasuhn <<a href="mailto:mike@mikeyp.net">mike@mikeyp.net</a>> wrote:<br>
>><br>
>> How are you updating the field?<br>
>> __________________<br>
>> Michael Prasuhn<br>
>> <a href="http://mikeyp.net" target="_blank">http://mikeyp.net</a><br>
>><br>
><br>
> Directly in the database..<br>
><br>
> I know its bad and it means none of the Drupal hooks run but its the only<br>
> way we could do this one particular update easily and in testing other than<br>
> it not displaying immediately it doesn't seem to have any adverse effects..<br>
<br>
</div></div>By directly do you mean using SQL or node_load/node_save? You should<br>
never use SQL to directly update the node. You may programmatically<br>
update it using node_load, modify object parameter then follow with<br>
node_save. This allows all the other node hooks to operate properly.<br>
<div class="im HOEnZb"><br>
--<br>
Earnie<br>
-- <a href="https://sites.google.com/site/earnieboyd" target="_blank">https://sites.google.com/site/earnieboyd</a><br>
</div><div class="HOEnZb"><div class="h5">--<br>
[ Drupal support list | <a href="http://lists.drupal.org/" target="_blank">http://lists.drupal.org/</a> ]<br>
</div></div></blockquote></div><br><div>Yes I know but in this case we didn't have a choice so had to try it.. Its just updating a datetime field with a new value.. The testing we did didn't reveal any issues other than the fact that the cache needs to be cleared for the new values to show in Drupal..</div>
<div><br></div><div>Originally we tried updating with a CSV through the feeds module but there is a timezone bug in feeds that stops this working..</div>