• s.ravisankar - Thursday, December 7, 2017 4:15 AM

    Hi,

    I have table x, table y

    table x have millions of record, so i want to insert data by multiple batches into table y.

    Since I have millions of record, batch size should be configurable and after insert it should close loop based on count in table x.

    Thanks in advance🙂

    Regards
    Ravi

    1.  How many "millions of record"?
    2.  How many bytes does the average "record" contain?
    3.  Are both tables in the same database, different databases on the same instance, different instances, or what ???

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)