Hi,
Can someone (crlab) confirm the next situation:
1. TORAStoredProc connected to a stored proc returning a cursor (dataset)
2. TClientDataSet grabs the dataset over TDataSetProvider.
3. A persistent set of fields is created on the client dataset level.
4. All fields are manually marked as "Required = false"
Upon "Post" a DBClient error "Field value is required" is thrown.
Now, all the fields are marked as non required - yet Delphi throws the exception.
Now, after 3 days of reading about TClientDataSet and TDataSetProvider I've figured out that the "problem" is inside the TORAStoredProc.
Option.RequiredFields is TRUE by default.
Since I'm editing my client dataset and will send changes back to the database using a series of insert/update statements .. I do not need this "Options.RequiredFields" to be set to true by default.
Am I right in presuming that "Options.RequiredFields =default= true" is my problem?
I have tons of TORAStoredProc controls where this should be set to "false".
Options.RequiredFields and TClientDataSet
Yes, but I'm trying to update my client dataset where all the persistent fields are set Required = false.Plash wrote:Yes, the error occurs because Required property of the fields in the TOraStoredProc component is set to True.
In what way is (why) this RequiredFields Option related to my client dataset?
Pardon my ignorance, by why does the provider check my client dataset? I'm not applying updates back to the dataset using provider.Plash wrote:When RequiredFields option is set to True, the The provider checks that a field in the TOraStroredProc component is required, and raises the error.
I just want to post a new record in my client dataset (memory) - not "currently" related to the stored procedure.