Record reference within a LOOP step

I have the flat file as
ROCdetails
1Details
2Details
1Details
2Details

1Details
2Details

How can I create the schema for this file