SQL QUERY - DUPLICATING THE RECORDS

  • Hello,

    I have the records set as follow:

    COL1COL2COL3

    1 120

    1130

    1141

    1151

    And Wanted the output from above recordset as follows:

    COL1COL2COL3Group

    11201

    11301

    11411

    11202

    11302

    11512

    Can anyone please suggest the way AND SQL Query to duplicate the row 1 and 2 against row 3 and 4?

    Thanks

    Shuaib

  • Cross join the table or join it to itself.

    Please post DDL statements, and the query you tried.

  • Attached the Test Script File. CROSS JOIN didn't work.

  • I have got the solution. CROSS JOIN worked for me.

    Thanks

Viewing 4 posts - 1 through 3 (of 3 total)

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