Additional
dbCAP
AnyDAC
ThinDAC
NCOCI8
Topic: Master/Detail Help!!! (Details)
Master/Detail Help!!! (Details)
Posted: 2001/02/13 01:13
 
Hi.
I have a TOCIQuery and a TDataSource connected to it. The TOCIQuery has a SQL sentence like: select * from Stations (Where StationId is the primary key). Now i want to make a Master/Detail relation with other TOCIQuery. Then i connect the dataset with the previous TDataSource and use the SQL sentence: select * from DailyInfoStations I where I.StationId = tationId. Then i think they are connected, but the second TOCIQuery doesn´t have any row. If i try to make it in run time (TOCIQuery.SQL := ...), when i call ExecuteSQL a exception raise: "Can not call ExecSQL for statement with rowset". What i am doing wrong. (In oracle DataBase, the records exists and i can retrieve those records using the OracleSQL*Plus program).
RE: Master/Detail Help!!! (Details)
Posted: 2001/02/14 09:38
 
Hi !

1) ExecSQL you should use only for DML commands, such as: INSERT/UPDATE/DELETE and for DDL and control commands. For SELECT's use Open.

2) Complex to say, what is wrong with your case ... Could you send me small demo, please ?

Regards,
Dmitry