| From: | Peter <peter(at)greatnowhere(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | Richard Huxton <dev(at)archonet(dot)com>, pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Weird double single quote issue |
| Date: | 2006-11-03 09:51:46 |
| Message-ID: | 454B1132.6090108@greatnowhere.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
>> 2. No. In fact I can replicate the problem on the same computer using
>> PgAdmin (connecting as two different users)
>> 3. I can isolate the part but it does not help much. I'm even doing
>> RAISE NOTICE and printing out the actual SQL statement that is being
>> executed... and it's IDENTICAL for both users yet returns different
>> values. Executing exactly the same SQL statement from commandline
>> produces identical results for both users.
>>
>
> It's really pretty hard to believe that the same function would work
> differently for two different users. I'm wondering if maybe the two
> users aren't executing the same function --- perhaps not the specific
> one you are looking at, but some other one it depends on. Do the
> users have different search_path settings?
>
>
I totally follow you. It really is hard to believe that the same code
can be executed differently for different users. I did double-check that
db is the same, and the actual proc being executed is the same. There
are no significant dependencies to speak of... I did full trace (via
RAISE NOTICE calls) and the SQL string being executed was exactly the
same for both users, and did not involve calls to user-defined funcs.
We upgraded to 8.1.4 overnight, and I rewrote my code to use
quote_literal() function, and that seems to have helped - at least
results are now consistent across users. I still have no idea what was
the cause, but it was definitely there....
Peter
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Martijn van Oosterhout | 2006-11-03 10:07:53 | Re: start up and shut down script |
| Previous Message | Oleg Bartunov | 2006-11-03 08:54:05 | Re: [HACKERS] Index greater than 8k |