To reproduce the issue, follow these steps:
- Start a new VCL project
- Drop a TMSConnection, TMSQuery, TDataSetProvider, TClientDataSet and TButton to the form
- Configure and open the connection, write a valid SQL for the MSQuery1 component and add all fields
- Create a new calculated field on MSQuery1
- Set MSQuery1 as the DataSet property of the DataSetProvider1 component
- Set 'DataSetProvider1' as the ProviderName property of the ClientDataSet1 component
- Write a OnClick event handler to the Button1 component with this code:
Code: Select all
ClientDataSet1.Open
The catastrophic error message will show. Prior to that, the IDE reports a AccessViolation error:
Code: Select all
Project Project1.exe raised exception class $C0000005 with message 'access violation at 0x00860a18: read of address 0x00000008'.
I've isolated the problem and to be sure the issue is related to SDAC, I've done the same setup using ADO, and it works fine.