Page 1 of 1

parent child initial loading

Posted: Fri Aug 14, 2009 11:36 am
by DSRajesh
Dear All,

I have two empty master detail tables say journey (journeyid is PK) AND Trucks(Truckid is pk,journeyid if FK)
i have loaded master table records and i need to load second table Trucks where i need to populate journeyid values from Journey table.
as Trucks is an emptty table ,i dont have any matching keys bewteen Journeys and Trucks.then how can i load the trucks with journeyid column from master table journeyid values.

can any one suggest me on this about approach.

thanks
raj

Posted: Fri Aug 14, 2009 1:28 pm
by Sainath.Srinivasan
Not sure what you are asking.

You must investigate your source systems to see what is available.

Posted: Fri Aug 14, 2009 1:39 pm
by chulett
That would be a question to an Analyst or Modeler at your site, not sure how anyone else would know your data / structures. :?

Re: parent child initial loading

Posted: Fri Aug 14, 2009 4:33 pm
by hiral.chauhan
DSRajesh wrote:Dear All,

I have two empty master detail tables say journey (journeyid is PK) AND Trucks(Truckid is pk,journeyid if FK)
i have loaded master table records and i need to load second table Trucks where i need to populate journeyid values from Journey table.
as Trucks is an emptty table ,i dont have any matching keys bewteen Journeys and Trucks.then how can i load the trucks with journeyid column from master table journeyid values.

can any one suggest me on this about approach.

thanks
raj

You need to find out the relationship between your Journey table and your Trucks table. Something like

One truck can make Many Journeys.

Then you can select JourneyId where truck = 'MyTruck'

Does that make sense?


-Hiral