pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedcharacter varying exceeded
3+ messages / 3 participants
[nested] [flat]
* character varying exceeded
@ 2008-05-20 15:19 Marc Fromm <Marc.Fromm@wwu.edu>
0 siblings, 2 replies; 3+ messages in thread
From: Marc Fromm @ 2008-05-20 15:19 UTC (permalink / raw)
To: pgsql-admin
WE have a db with a column/field of type "character varying" set to a
length of 1000. A user attempted to enter data into this column/field
breached the 1000 limit. When the user submitted the form the data was
not entered into the database and no error or message was displayed.
Is there a way to have postgresql let the user no the entry attempt was
declined? What is the best way to handle these situations?
Marc
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: character varying exceeded
@ 2008-05-20 15:30 Chander Ganesan <chander@otg-nc.com>
parent: Marc Fromm <Marc.Fromm@wwu.edu>
1 sibling, 0 replies; 3+ messages in thread
From: Chander Ganesan @ 2008-05-20 15:30 UTC (permalink / raw)
To: Marc Fromm <Marc.Fromm@wwu.edu>; +Cc: pgsql-admin
Marc Fromm wrote:
> WE have a db with a column/field of type "character varying" set to a
> length of 1000. A user attempted to enter data into this column/field
> breached the 1000 limit. When the user submitted the form the data was
> not entered into the database and no error or message was displayed.
>
> Is there a way to have postgresql let the user no the entry attempt was
> declined? What is the best way to handle these situations
PostgreSQL does indicate that the statement failed. Chances are your
application code (that does the insert) is ignoring the error. You
should check your application code to ensure that it's handling error
messages on insert failures correctly, and notifying the user as
appropriate.
--
Chander Ganesan
Open Technology Group, Inc.
One Copley Parkway, Suite 210
Morrisville, NC 27560
919-463-0999/877-258-8987
http://www.otg-nc.com
Ask me about OTG's Expert PostgreSQL, PostGIS, PHP, and other Open Source training offerings.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: character varying exceeded
@ 2008-05-20 15:38 Andrew Sullivan <ajs@commandprompt.com>
parent: Marc Fromm <Marc.Fromm@wwu.edu>
1 sibling, 0 replies; 3+ messages in thread
From: Andrew Sullivan @ 2008-05-20 15:38 UTC (permalink / raw)
To: pgsql-admin
On Tue, May 20, 2008 at 08:19:56AM -0700, Marc Fromm wrote:
> breached the 1000 limit. When the user submitted the form the data was
> not entered into the database and no error or message was displayed.
I think your application is broken. There was so an error message
generated. It sounds like your application didn't catch it or display
it.
If you're using straight psql, then the problem is that
client_min_messages is set too high, and clients aren't seeing
errors. That's surely a mistake.
A
--
Andrew Sullivan
ajs@commandprompt.com
+1 503 667 4564 x104
http://www.commandprompt.com/
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2008-05-20 15:38 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2008-05-20 15:19 character varying exceeded Marc Fromm <Marc.Fromm@wwu.edu>
2008-05-20 15:30 ` Chander Ganesan <chander@otg-nc.com>
2008-05-20 15:38 ` Andrew Sullivan <ajs@commandprompt.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox