method

with_identity_insert_enabled

with_identity_insert_enabled(table_name, &block)
private

Turns IDENTITY_INSERT ON for table during execution of the block N.B. This sets the state of IDENTITY_INSERT to OFF after the block has been executed without regard to its previous state