This is how my db components are connected in program:

The datatypes of components are (first row, from left to right): TDBGrid, TDataSource, TClientDataSet, TDataSetProvider, TSQLQuery, TSQLConnection. Second row is analogous to first row.
Client data set Query_LimitDetail is linked to master data source through properties MasterSource and MasterFields. Their values are as follows:
Query_LimitDetail->MasterSource = DataSource_Limit;
Query_LimitDetail->MasterFields = L"ID";
SQL command assigned to client data sets are:
select * from LIMIT order by NAME
select * from LIMITDETAIL where LIMIT_ID = :ID order by ACCUR
This is how i open queries:
Query_Limit->Open();
Query_LimitDetail->Open();
When trying to open detail query, program throws following error:
dbExpress driver does not support the TDBXTypes.UNKNOWN data type. Vendor error message: unknown ISC error 0
Is there something I didnt make correctly?
The solution is to set SQL parameter type just before opening the query:
Alternative and more universal solution is to set parameter type in OnBeforeOpen event handler like this:
It is also neccessary to link column in master table (specified in
MasterFieldsproperty) to column in detail table: