Facing trouble in insertion of data in to table after creating table by using hook_update_N function
If you're using drupal_write_record, be aware of this warning in the documentation


  Do not use drupal_write_record() within hook_update_N() functions, since the database schema cannot be relied upon when a user is running a series of updates. Instead, use db_insert() or db_update() to save the record.


You should be using db_insert or db_update instead.