Ideally you would have an External Id that you could use for the mapping instead of the Salesforce Id. If so you should just be able to use the dataloader by using the External Id.
The Salesforce Id will be different across Orgs. Because of this the Id values in your current export will not exist in your Sandbox. What you will need to do is:
- Import all your Parent records (maintaining the old sf Id - or some other identifier)
- Export your parent records from sandbox (this will get you the new Ids)
- Cross reference the new export with the old using the identifier. (This could be a lookup in excel or do some sort of data scripting)
- In your child import file replace the Parent Id with the Cross reference Id from the new data set.
I usually write script that will do the data lookup and replace for me. Without an external id you will need to do some data processing.