Create Auto Insert Script - 500k records to load data into sql server

  • Hi,

    I would like to Create Auto Insert Script - 500k records to load data into sql server for my testing.

    How can i generate dummy table and data script?

    I have sql server 2008 and 2012 version.

    Thanks

  • Jeff Moden did some articles on this. Start here and see how you get on.

    The absence of evidence is not evidence of absence.
    Martin Rees

    You can lead a horse to water, but a pencil must be lead.
    Stan Laurel

  • Actually I need to Createa simple CSV and upload it to sql server and OR other application.

    Your help really Appreciated it!

    Thanks.

  • poratips - Tuesday, June 20, 2017 7:57 AM

    Actually I need to Createa simple CSV and upload it to sql server and OR other application.

    Your help really Appreciated it!

    Thanks.

    Use Jeff's technique to create a dummy table, and then use BULK EXPORT to output the data to a CSV file.

    Steve (aka sgmunson) 🙂 🙂 🙂
    Rent Servers for Income (picks and shovels strategy)

  • poratips - Tuesday, June 20, 2017 7:28 AM

    Hi,

    I would like to Create Auto Insert Script - 500k records to load data into sql server for my testing.

    How can i generate dummy table and data script?

    I have sql server 2008 and 2012 version.

    Thanks

    what data columns and datatypes are you intending to create?
    do have specific data ranges that need to be addressed?

    ________________________________________________________________
    you can lead a user to data....but you cannot make them think
    and remember....every day is a school day

  • Thanks.
    I need just number, data and varchar type but it will be ok any kind of data as i am testing connectivity.

  • poratips - Tuesday, June 20, 2017 9:31 AM

    Thanks.
    I need just number, data and varchar type but it will be ok any kind of data as i am testing connectivity.

    so why the need for 500k records?
    just knock something up in excel and save as csv?

    ________________________________________________________________
    you can lead a user to data....but you cannot make them think
    and remember....every day is a school day

Viewing 7 posts - 1 through 6 (of 6 total)

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