 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Robert Wheadon Guest
|
Posted: Fri Jun 18, 2004 1:39 am Post subject: Posting a record raises an exception wnen I enter a Zero Len |
|
|
Hello,
I am making a program which reads and writes data from an Access 97
database. There are some a couple of string fields that my program reads
and writes to. These fields update properly when I enter a non-zero length
string into them. When I enter a zero length string in one of them and call
TTable::Post(), I get a EDBEngineError exception. The error message reads:
General SQL error.
Field 'Terminal.TermShortDescription' can't be a zero-length string.
Table
Any ideas about why this is happening?
Thanks,
Robert Wheadon
|
|
| Back to top |
|
 |
Robert Wheadon Guest
|
Posted: Tue Jun 29, 2004 5:47 am Post subject: Re: Posting a record raises an exception wnen I enter a Zero |
|
|
I have fixed this problem by checking if the field is empty and calling the
TField::Clear() function to set the field to NULL.
- Robert.
"Robert Wheadon" <robert.wheadon (AT) monitorbm (DOT) co.nz> wrote
| Quote: | Hello,
I am making a program which reads and writes data from an Access 97
database. There are some a couple of string fields that my program reads
and writes to. These fields update properly when I enter a non-zero
length
string into them. When I enter a zero length string in one of them and
call
TTable::Post(), I get a EDBEngineError exception. The error message
reads:
General SQL error.
Field 'Terminal.TermShortDescription' can't be a zero-length string.
Table
Any ideas about why this is happening?
Thanks,
Robert Wheadon
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|