Direct database querying: pros and cons
Posted on behalf of dman@drupal.org:
From http://basement.greenash.net.au/soc2006/ImportExportApiModule?show_comments=1#comment_19:
Read moreWhere is good for discussions? A Drupal.org thread, the issues register, or somewhere here? I'd rather keep it open than emails.
Granted you may not be ready for a code review yet :) I had a quick look and was surprised you are attacking the database directly. Wouldn't it be better to let Drupal continue to handle the serialization, and get (eg) user_load() or node_load() to instantiate the php object, and base your mappings to that structure? By digging directly at the database (clever though your structure mapping system is) you are bypassing a lot of Drupal goodness, especially once you come to node_load().
