Skip site navigation (1) Skip section navigation (2)

Re: ERROR: invalid input syntax for integer: ""

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: "Pit M(dot)" <fmi-soft(at)gmx(dot)de>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: ERROR: invalid input syntax for integer: ""
Date: 2007-05-23 15:43:01
Message-ID: 46546105.30602@hagander.net (view raw or flat)
Thread:
Lists: pgsql-bugs
Pit M. wrote:
> 
>> It would have failed if you had run the cursor far enough to fetch one
>> of the bad rows.
>>
>>             regards, tom lane
>>
> The difference is that in one case the query fails and in the other the
> FETCH command fails.
> 
> 
> Our problem is that if a query succeeds we use a count(*) of that query
> to display the result count in the status bar of our application - the
> select works but the count(*) fails :-)
> When we use this query on MS SQL-Server the query fails directly though
> we also use cursors here. So the SQL-Server somehow checks all the data
> only for the query -> perhaps because we used a server side cursor.

IIRC, the behavior of MSSQL will depend on the query plan. If it's a
plan that requires doesn't require materialization at all, it won't
figure it out until you get there.

//Magnus

In response to

Responses

pgsql-bugs by date

Next:From: Tom LaneDate: 2007-05-23 15:59:43
Subject: Re: ERROR: invalid input syntax for integer: ""
Previous:From: Pit M.Date: 2007-05-23 15:31:38
Subject: Re: ERROR: invalid input syntax for integer: ""

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group