Unidac, Oracle and Insert/update

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
polsol
Posts: 71
Joined: Sun 20 May 2007 13:29
Contact:

Unidac, Oracle and Insert/update

Post by polsol » Tue 19 May 2015 09:11

Hi,

I have an application that requires the addition of a required textfield in a separate component for addition to a grid table.
If the user attempts to add a record from a grid without filling in the external textfield there's obviously a response of not accepting a 'null field'. Filling in the textfield and hitting 'Post' comes back with the same error.
I have added an 'OnUpdateData' to fill in the field if it's mistakenly left blank but this approach is somewhat 'inelegant' (from my perspective).
Similarly, making changes to a record and updating the data with a blank textfield has the same issues - one has to use the 'OnUpdateData' route when hitting 'post' again.
Is there a way to ensure that the insert/update Post works with all the fields (i.e. will 'accept' the input from the textfield when it's properly filled in)? Seems that Post ignores changes to the external textfield after an Insert or Update has failed. :cry:
I tried 'UpdateAllFields' in the TQuery but this doesn't work either.
I am using a DevExpress DBGrid - not sure if this has anything to do with this?
Suggestions?

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Re: Unidac, Oracle and Insert/update

Post by AlexP » Wed 20 May 2015 08:29

Hello,

Try to reproduce the issue using the standard components: DBGrid, DBMemo[DBEdit]. And let us know the result.

Post Reply