Possible, yes. Recommended, no. I do a lot of importing from outside sources, and would never entertain using direct SQL INSERT
statements.
I would export your existing database in another format, and pursue one of standard approaches.
The easiest is probably Feeds. In your case, I would export as CSV, and then use the CVS imported built into feeds. Based on your description, it sounds like you have a one-to-one mapping, and the CSV importer is good for this.
The Migrate module can also handle moving data from one source into Drupal.
A more robust solution would be to create a custom importer, build up a $node
, and then use node_save
. There are a lot of nuances with this, and this is not a good approach unless you are familiar with the Drupal API already.