Loading data through insert scripts takes so much time.

  • I am creating and loading data through scripts scripts.

    There are two tables which are having records around 2lacs and 45 lacs.

    For these two tables I have created insert scripts having format as follows,

    Insert into Table_name (Column1,column2,...) values(value1,value2,...)

    The problem running these scripts is they are consuming so much time,nearly 3 to 4 hours.

    I have tried the option of bulk insert but it is not producing the exact data that is in scripts.

    So can any one tell If I use ,

    Insert into Table_name (columns...)

    select value1,value2....

    union all

    select value1,value2....

    union all

    select value1,value2....

    will the performance get better or same as the scripts.

    If any other option is there please give the suggestion.

  • All reply should post here

    http://www.sqlservercentral.com/Forums/Topic633185-338-1.aspx

    Don't do double post!

    ================================================================================

    ============================================================
    SELECT YOUR PROBLEM FROM SSC.com WHERE PROBLEM DESCRIPTION =
    http://www.sqlservercentral.com/articles/Best+Practices/61537/[/url]

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply