Relational / Hierarchical Select
Posted: Thu 28 Feb 2008 02:57
Is there an elegant way to do a select on a parent table which then only retrieves its child rows based on what was selected in the parent table?
Basically, I'd like to use the built in feature of startrecord and maxRecords. I'd like to say, give me the first 4k records of this parent table and also retrieve all child tables that belong to the selected 4k records. In this way, you won't fail a contraint check, where as you would possibly if you said just give me the first 4k records in both parent and child tables. Obviously, in a larege database you can't simply say Select all.
Is there a built in way to do this?
Basically, I'd like to use the built in feature of startrecord and maxRecords. I'd like to say, give me the first 4k records of this parent table and also retrieve all child tables that belong to the selected 4k records. In this way, you won't fail a contraint check, where as you would possibly if you said just give me the first 4k records in both parent and child tables. Obviously, in a larege database you can't simply say Select all.
Is there a built in way to do this?