On Thu, 16 Oct 2003, Kathy Zhu wrote:
Hi,
I got this message. Is that because the string id too long ??
Are you sure testid is defined as a string type and not an integer?
That'd be the most likely reason for pg_atoi to be called.
insert into test (testid)
Hi,
I got this message. Is that because the string id too long ??
Where is the String length defined ??
thanks,
Kathy
insert into test (testid)
values('FAKEJOBMGRNAMEJOBNAME-020031016211324.144-06002elID--0jobname-0Thu Oct16
21:13:24 MDT 2003');
ERROR: pg_atoi: error in
Richard Harvey Chapman [EMAIL PROTECTED] writes:
Is there a reason why pg_atoi() was programmed to fail if the entire
input string is not valid?
i.e. "109" yields 109, but "109 apples" yields an error.
Because that's what it ought to do, if you ask me ;-).
"109 foo" is not a valid integer
Is there a reason why pg_atoi() was programmed to fail if the entire
input string is not valid?
i.e. "109" yields 109, but "109 apples" yields an error.
Snippet from pg_atoi() in src/backend/utils/adt/numutils.c:
l = strtol(s, badp, 10);
if (errno) /*