Board index » delphi » Master detail with IBTable and IBQuery

Master detail with IBTable and IBQuery

I m affront problems with the use of master/detail on IBTable and IBQuery
components. I tried with  IBTable, setting the properties MasterSource and
MasterFields of detail table to indicate the master table. This was not
correct.

I tried too with IBQuery (join IBUpdateSQL), pass parameters to detail
query. This was not correct too.

Anyone can help me?

Any example

Thanks

Ricardo

_________________________________________ Ricardo Fantinelli ICQ#:170682141
Current ICQ status: SMS: (Send an SMS message to my ICQ): +2783142170682141
More ways to contact me: http://wwp.icq.com/170682141
_________________________________________

 

Re:Master detail with IBTable and IBQuery


Use two IBDataSets. Set the DataSource property of the child to the
DataSource component of the parent. Use a parameterized SELECT for the
child that includes the foreign key in the WHERE clause as a
parameter.

--
Bill (TeamB)
(TeamB cannot respond to questions received via email)

Re:Master detail with IBTable and IBQuery


Quote
>Just to be clear - do you have to rerun the SQL in the OnChange event of
>the Master dataset?

No. Everything happens automatically. You do not need to write any
code.

--
Bill (TeamB)
(TeamB cannot respond to questions received via email)

Re:Master detail with IBTable and IBQuery


Quote
>What would be a good choice for a component to choose a master value
>(something like a combo box) and what would be the right settings?

Choose a master value for what? What do you mean by "a master value"?
What are you trying to do?

--
Bill (TeamB)
(TeamB cannot respond to questions received via email)

Re:Master detail with IBTable and IBQuery


Quote
>I mean a component to set the current row in the master dataset, like a
>DBGrid does, but maybe in a more elegant way (since it won't need all the

The TDBNavigator will let you move the cursor to any row in the
dataset.

--
Bill (TeamB)
(TeamB cannot respond to questions received via email)

Other Threads