🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.database.dbexpress
1 messages
1 total messages Started by Vanessa Deagan Wed, 03 Aug 2005 12:49
Master Detail relationship with TSQLClientDataSet
#148
Author: Vanessa Deagan
Date: Wed, 03 Aug 2005 12:49
28 lines
1944 bytes
Hi,

I'm using BCB6 Ent and MySQL 4.0.23. I'm trying to setup a master/detail 
relationship using:

SQLConnection1
SQLClientDataSet1, DataSource1
SQLClientDataSet2, DataSource2


The master TSQLClientDataSet:
SQLClientDataSet1->CommandText = "select id, parent_id, name from Category 
where parent_id = :parent_id";

The detail TSQLClientDataSet:
SQLClientDataSet2->CommandText = "select cat_id, board_name from 
BoardCateogryMap where cat_id = :id";

I then set SQLClientDataSet2.MasterSource to DataSource1, and I then press 
the eclipse for SQLClientDataSet2's MasterFields property, and this brings 
up the "Field Link Designer". I select the fields used in the relationship 
(Detail Field = cat_id, Master Field = id), but am then greeted with a 
"Field id not found".

Could someone please post simple instructions to setup master/detail 
relationship usnig TSQLClientDataSets.

Many thanks.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads