Re: [HACKERS] fixing PQsetvalue()

2011-06-23 Thread Andrew Chernow
reated via PQmakeEmptyPGresult, including libpqtypes. Actually, libpqtypes calls PQcopyResult which calls PQmakeEmptyPGresult. It might be better to say a "server" result vs. a "client" result. Currently, PQsetvalue is broken when provided a "server" generated resul

Re: [HACKERS] Libpq enhancement

2011-06-19 Thread Andrew Chernow
. Have you looked into libpqtypes? It allows you to pack nested structures/arrays and pass them as query/function parameters. http://pgfoundry.org/projects/libpqtypes/ http://libpqtypes.esilo.com/ (docs) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql

Re: [HACKERS] Error in PQsetvalue

2011-06-08 Thread Andrew Chernow
ak. Maybe it would be better to just apply the patch (since it also removes duplicate code from pqAddTuple in addition to fixing a crash) and update the docs to say this is an unsupported feature, don't do it. If it happens to work forever or just for a while, than so be it. -- Andr

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
On 6/3/2011 10:26 PM, Andrew Chernow wrote: I disagree -- I think the fix is a one-liner. line 446: if (tup_num == res->ntups&& !res->tuples[tup_num]) should just become if (tup_num == res->ntups) also the memset of the tuple slots when the slot array is expanded can be remo

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
nants of an older idea that caused the bug. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ diff --git a/src/interfaces/libpq/fe-exec.c b/src/interfaces/libpq/fe-exec.c index 83c5ea3..9f013ed 100644 --- a/src/interfaces/libpq/fe-exec.c +++ b/src/interfaces/libpq/fe-exec.c @@ -

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
On 6/3/2011 7:14 PM, Merlin Moncure wrote: On Fri, Jun 3, 2011 at 6:22 PM, Andrew Chernow wrote: Actually, the original idea, as I stated UT, was to allow adding tuples in any order as well as overwriting them. Obviously lost that while trying to get libpqtypes working, which only appends

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
On 6/3/2011 5:54 PM, Merlin Moncure wrote: On Fri, Jun 3, 2011 at 3:38 PM, Andrew Chernow wrote: Eeekks. Found an additional bug. PQsetvalue only allocates the actual tuple if the provided tup_num equals the number of tuples (append) and that slot is NULL. This is wrong. The original idea

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
w the tuple table; in which case new elements are zero'd. OP attempted to append. res = PQexec("returns 2 tuples"); PQsetvalue(res, PQntuples(res), ...); -- Andrew Chernow eSilo, LLC global backup http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@pos

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
On 6/3/2011 4:06 PM, Andrew Chernow wrote: On 6/3/2011 3:03 PM, Pavel Golub wrote: Hello. Reproduced under Windows XP SP3 using Visual C++ 2008 and Delphi. If PQsetvalue is called with second parameter equals to PQntuples then memory corruption appears. But it should grow internal tuples array

Re: [HACKERS] Error in PQsetvalue

2011-06-03 Thread Andrew Chernow
line 446 on fe-exec.c. I never tested this case since libpqtypes never tried to call PQsetvalue on a PGresult created by the standard libpq library. The solution I see would be to zero the new table slots within pqAddTuple. Any other ideas? -- Andrew Chernow eSilo, LLC global backup

Re: [HACKERS] PQdeleteTuple function in libpq

2011-06-02 Thread Andrew Chernow
optimized for your requirement. -- Andrew Chernow eSilo, LLC global backup http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] PQdeleteTuple function in libpq

2011-06-02 Thread Andrew Chernow
keEmptyPGresult, PQsetResultAttrs and PQsetvalue to construct a result that excludes the tuples you don't want followed by a PQclear(initial_result)? Actually the best solution would be to call PQcopyResult with all PG_COPYRES_XXX flags enabled except PG_COPYRES_TUPLES. Now call PQsetvalue f

Re: [HACKERS] PQdeleteTuple function in libpq

2011-06-02 Thread Andrew Chernow
you are trying to do, but can't you use PQmakeEmptyPGresult, PQsetResultAttrs and PQsetvalue to construct a result that excludes the tuples you don't want followed by a PQclear(initial_result)? -- Andrew Chernow eSilo, LLC global backup http://www.esilo.com/ -- Sent via pgsql-hackers mailing list

Re: [HACKERS] PQdeleteTuple function in libpq

2011-06-01 Thread Andrew Chernow
ation. You could track tuples removed in an int[] or copy the result set into an application defined array of C structures. I've always been under the impression that PGresult objects are immutable once delivered to the application. -- Andrew Chernow eSilo, LLC global backup http://www

Re: [HACKERS] windows consolidated cleanup

2011-04-24 Thread Andrew Chernow
taking one argument. // guc-file.c line 354 #define GUC_yywrap(n) 1 The macro is overriding the prototype declared at line 627, which has a void argument list (assuming YY_SKIP_YYWRAP is !defined). Since all code references to this do not provide an argument, I'd say the macro is incorrect. --

Re: [HACKERS] Itanium HP-UX build failure, register stack

2011-04-13 Thread Andrew Chernow
23 U ia64 They are build farm boxes (which already build postgres) so my guess is they wouldn't require much fiddling. I don't time to help with this, but am more than willing to give you all the access you need to get it going. I also have HP-UX 10.20 on a PA-RISC for the courageous.

Re: [HACKERS] Correctly producing array literals for prepared statements

2011-02-23 Thread Andrew Chernow
ntf/scanf style interface. PQexecf(conn, "select %int4 + %int4", 4, 4) is pretty far removed from the underlying byte swapping, parallel array setup for PQexecParams and other nastiness. But yes, the maintainer of the library must deal with protocol changes and provide backward compati

Re: [HACKERS] Correctly producing array literals for prepared statements

2011-02-23 Thread Andrew Chernow
Personally, PQexec is dead to me as well as text results from a C/C++ app. I see no advantage over libpqtypes in that context. Unless I am missing your ultimate goal, you'd probably get what you want by wrapping libpqtypes. -- Andrew Chernow eSilo, LLC global backup http://www.esilo.co

Re: [HACKERS] Correctly producing array literals for prepared statements

2011-02-23 Thread Andrew Chernow
/libpqtypes. We do need some support in libpq for constructing and deconstructing arrays (and probably for composites too, although that will be harder, I suspect). [sigh...] -- Andrew Chernow eSilo, LLC global backup http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers

Re: [HACKERS] Visual Studio 2010/Windows SDK 7.1 support

2011-01-15 Thread Andrew Chernow
if you'd like. Wouldn't be until Monday or Tuesday. Any preference on windows version? Maybe Windows 7? You want 64-bit? Send a private email. -- Andrew Chernow eSilo, LLC global backup http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.or

Re: [HACKERS] Suggesting a libpq addition

2010-12-27 Thread Andrew Chernow
to consider libpqtypes for contrib (which we don't have time for atm). ... or as a libpq sibling :) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription:

Re: [HACKERS] [GENERAL] queriing the version of libpq

2010-12-16 Thread Andrew Chernow
f you were attempting to detect behavior differences. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Suggesting a libpq addition

2010-12-06 Thread Andrew Chernow
27;ve just made a more formal set of utility functions, typically called an API, in an attempt to match the coding standards of the postgresql project. There is no libpq param interface like results, so we added PGparam stuff. This allows you to pack parameters (PQputf) and than execute it.

Re: [HACKERS] Suggesting a libpq addition

2010-12-06 Thread Andrew Chernow
uot;%my_type" libpqtypes allows you to register aliases (PQregisterSubClasses) so that you can map %text to %s to make it feel more like C.. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Suggesting a libpq addition

2010-12-05 Thread Andrew Chernow
A varargs version of PQexecParams() would be handy, though. Imagine being able to do: PQexecVParams("SELECT * FROM mytable WHERE foo = $1 AND bar = $2", foovar, barvar); instead of constructing an array for the variables. http://libpqtypes.esilo.com/man3/PQexecf.html -- Andr

Re: [HACKERS] Suggesting a libpq addition

2010-12-05 Thread Andrew Chernow
beginning http://libpqtypes.esilo.com http://pgfoundry.org/projects/libpqtypes/ -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref

Re: [HACKERS] returning multiple result sets from a stored procedure

2010-09-05 Thread Andrew Chernow
arr); Now loop the array "arr" and getf(arr.res) for each rev_t, which allows you to getf each fork_t in the fork_t[], etc I *know* it is not pure multiset'n, but it sure gets the job done (in a completely different way, I know). However, I'm sure those reading this lis

Re: [HACKERS] Keepalives win32

2010-06-28 Thread Andrew Chernow
VS.85).aspx Patch as it looks now (libpq only, and with obvious problems with this issue): http://github.com/mhagander/postgres/compare/master...win32keepalive and here :) http://archives.postgresql.org/pgsql-hackers/2009-05/msg01099.php -- Andrew Chernow eSilo, LLC every bit counts

Re: [HACKERS] Keepalives win32

2010-06-28 Thread Andrew Chernow
umber of parallell connections we can deal with on the server side (on win32 at least, not sure about win64). Oh, didn't know that. Are the standard reg functions, open/query/close really that bad? Can't be any worse than the security api or MAPI hell ;) -- Andrew Chernow eSilo

Re: [HACKERS] libpq, PQexecPrepared, data size sent to FE vs. FETCH_COUNT

2010-05-25 Thread Andrew Chernow
of data) reside after I call | PQexecPrepared? On BE, I hope? Sorry for asking again... No sarcasm meant: is there no straightforward answer here? Or nobody is certain? Or a wrong list? Issue multiple queries and make use of LIMIT/OFFSET. You'll have to go manual on this one. -- A

Re: [HACKERS] OpenVMS?

2010-02-16 Thread Andrew Chernow
unity approval. Otherwise, anyone with an idea would be a committer. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] TCP keepalive support for libpq

2010-02-11 Thread Andrew Chernow
DBI, psycopg, JDBC, etc... all enable or disable keepalives by default. I only bring this up because it appears there are complaints from non-libpq clients. This patch wouldn't fix those cases. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hack

Re: [HACKERS] TCP keepalive support for libpq

2010-02-11 Thread Andrew Chernow
d, there is no guarentee the driver will implement the new feature ... JDBC seems to lack the ability to get the backing Socket object but java can set socket options. Maybe a JDBC kong fu master knows how to do this. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent vi

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2010-02-09 Thread Andrew Chernow
binary payloads be an alternative? NOTE: I may have missed this discussion. Sorry if it has already been covered. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your sub

Re: [HACKERS] TCP keepalive support for libpq

2010-02-09 Thread Andrew Chernow
http://www.mail-archive.com/pgsql-hackers@postgresql.org/msg128603.html -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] 8.5 vs. 9.0, Postgres vs. PostgreSQL

2010-01-22 Thread Andrew Chernow
really advocating a name change, but if a different name makes postgresql more popular, however silly that may seem, then I am all for it. This is a difficult marketing decision. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing lis

Re: [HACKERS] 8.5 vs. 9.0

2010-01-21 Thread Andrew Chernow
9.0. You don't have a code-name. All the cool kids have code-names for their projects. Black Dog yup, I'm a zeppelin fan :) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make chang

Re: [HACKERS] Typed tables

2010-01-12 Thread Andrew Chernow
emoved nor do I sneer :) Honestly, I was only trying to understand why it existed. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Typed tables

2010-01-12 Thread Andrew Chernow
Peter Eisentraut wrote: On tis, 2010-01-12 at 08:05 -0500, Andrew Chernow wrote: In practice, tables can be used for passing data around or storing it on disk. So, I guess my question remains unanswered as to what the composite type offers that a table doesn't; other than a name that b

Re: [HACKERS] Typed tables

2010-01-12 Thread Andrew Chernow
Peter Eisentraut wrote: On mån, 2010-01-11 at 19:27 -0500, Andrew Chernow wrote: Peter Eisentraut wrote: On mån, 2010-01-11 at 15:02 -0500, Andrew Chernow wrote: ISTM that the ultimate would be a 'create table (_) without storage' (or some'm) and make 'create type'

Re: [HACKERS] Typed tables

2010-01-11 Thread Andrew Chernow
Peter Eisentraut wrote: On mån, 2010-01-11 at 15:02 -0500, Andrew Chernow wrote: ISTM that the ultimate would be a 'create table (_) without storage' (or some'm) and make 'create type' an alternate syntax for SQL conformance. I don't really understand the p

Re: [HACKERS] Typed tables

2010-01-11 Thread Andrew Chernow
and use a c-like naming convenstion of appending _t to such beasts. I'll just throw a little meat into the pack wolvesconstraints? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2010-01-11 Thread Andrew Chernow
ytea. If all we want is utf8, then there is no issue with libpq. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2010-01-08 Thread Andrew Chernow
conversion problems in some circumstances - what about bytea (or why _do_ we have to limit this to something?). I agree with bytea. Zero conversions and the most flexible. Payload encoding/format should be decided by the user. -- Andrew Chernow eSilo, LLC every bit counts http

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2009-11-18 Thread Andrew Chernow
Tom Lane wrote: Andrew Chernow writes: Tom Lane wrote: There is only one correct overflow behavior. I count three. Waiting till you can insert is reasonable (especially if we have some behavior that nudges other backends to empty the queue). If by "skip" you mean losing the

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2009-11-18 Thread Andrew Chernow
Tom Lane wrote: Andrew Chernow writes: I mentioned this up thread. I completely agree that overflow behavior should be tunable. There is only one correct overflow behavior. I count three. 1. wait 2. error 3. skip #1 and #2 are very similar to a file system. If FS buffers are full on

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2009-11-18 Thread Andrew Chernow
viors via GUC: drop-oldest (as above) drop-largest (if we run out of room, drop the largest payloads first to save space) error (if we run out of room, error and rollback) I mentioned this up thread. I completely agree that overflow behavior should be tunable. -- Andrew Chernow eSilo, LLC ever

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2009-11-18 Thread Andrew Chernow
n at least it knows it should rescan the original data and rebuild the cache and not just serve invalid data. That's far more complicated than throwing an error and it discards user payload information. Let the error indicate a rescan is needed. -- Andrew Chernow eSilo, LLC every

Re: [HACKERS] Listen / Notify - what to do when the queue is full

2009-11-16 Thread Andrew Chernow
h the +1 -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] named parameters in SQL functions

2009-11-15 Thread Andrew Chernow
Tom Lane wrote: Andrew Chernow writes: Tom Lane wrote: (But having said that, an alternate qualification name is something that could be implemented if there were any agreement on what to use.) Would something like ARG.name be acceptable? It all depends on how likely you think it is that

Re: [HACKERS] named parameters in SQL functions

2009-11-15 Thread Andrew Chernow
g said that, an alternate qualification name is something that could be implemented if there were any agreement on what to use.) Would something like ARG.name be acceptable? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hacker

Re: [HACKERS] named parameters in SQL functions

2009-11-15 Thread Andrew Chernow
se already exists via $1 and "$1". Making '$' a marker for parameters wouldn't introduce it. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http:

Re: [HACKERS] named parameters in SQL functions

2009-11-15 Thread Andrew Chernow
ng of something like $abc$def, where abc and def are variables. Although, this is much less likely than column name conflicts. Other possibles are: $(var), @var@, or %var%. I'd perfer a single character marker but that may not fly. -- Andrew Chernow eSilo, LLC every bit counts http://www

Re: [HACKERS] named parameters in SQL functions

2009-11-15 Thread Andrew Chernow
se for similar purposes, but I think that would lead to ambiguity with dollar quoting. Would this be limited to sql functions? I only ask because for non-sql functions we currently prefix parameter names with an underscore, but a built-in special marker would be much more desirable. -- Andre

Re: [HACKERS] Listen / Notify rewrite

2009-11-13 Thread Andrew Chernow
erformance concerns are now in the hands of the DBA. Incidentally, I'd like to thank Joachim personally for having done this work, +1 -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to yo

Re: [HACKERS] Listen / Notify rewrite

2009-11-13 Thread Andrew Chernow
hat would fit in memory or not. This leads me to believe that the only safety in smaller payloads is *possibly* a smaller chance of bogging it down, but that all depends on the usage pattern of smaller vs. larger payloads which is system specific. -- Andrew Chernow eSilo, LLC every bit c

Re: [HACKERS] Listen / Notify rewrite

2009-11-13 Thread Andrew Chernow
ink the original OP was close. The structure can still be fixed length but maybe we can bump it to 8k (BLCKSZ)? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http:

Re: [HACKERS] Listen / Notify rewrite

2009-11-13 Thread Andrew Chernow
think its a side-track to discuss queue vs condition variables. Whether a notify is 20 bytes through the network or 8192 bytes doesn't change its design or purpose, only its size. Calling this a creeping feature is quite a leap. -- Andrew Chernow eSilo, LLC every bit counts http://www

Re: [HACKERS] Listen / Notify rewrite

2009-11-12 Thread Andrew Chernow
ould require an understanding of the context in which it was applied. For example, using our screw driver to remove a splinter would be rather stupid, IMHO ;) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] Listen / Notify rewrite

2009-11-12 Thread Andrew Chernow
hes, so make sure to use persistent storage for any payload worth keeping post-session. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Listen / Notify rewrite

2009-11-12 Thread Andrew Chernow
n was half-baked. NOTIFY is event-driven, ie. no polling! -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Listen / Notify rewrite

2009-11-12 Thread Andrew Chernow
s like the limitation comes from slru. The true payload limit is (8K - struct members) the way this is implemented. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscrip

Re: [HACKERS] Listen / Notify rewrite

2009-11-12 Thread Andrew Chernow
o finds this limit too small. I can almost guarentee complaints would come in if released that way. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
ers seems awfully small. I already have at few places in mind that would require more bytes. Why not 8K, 64K, 256K, 1M or even more? Is there some other factor in play forcing this limitation? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers ma

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
ad, I vote no. Maybe the NOTIFY command can include a switch to enable this behavior. No syntax suggestions at this point. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscri

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
ousand backends listening with a large queue would perform decently behind a linear search. At this point, I have no data either way; only an assumption based off being burnt by sequential scans in the past ;) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
Joachim Wieland wrote: On Thu, Nov 12, 2009 at 1:04 AM, Andrew Chernow wrote: I think a bsearch would be needed. Very busy servers that make heavy use of notifies would be quite a penalty. In such an environment, how many relations/channels is a backend typically listening to? Do you have

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
bool + IsListeningOn(const char *channel) I think a bsearch would be needed. Very busy servers that make heavy use of notifies would be quite a penalty. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] Listen / Notify rewrite

2009-11-11 Thread Andrew Chernow
em to work around for me. +1 -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] libpq - extending PQexecParams/PQexecPrepared to specify resultFormat for individual result columns

2009-11-02 Thread Andrew Chernow
result columns in different formats, although that is possible in the underlying protocol. So I made this possible.) Can you explain the use case for this? Have you investigated libpqtypes? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing

Re: [HACKERS] postgres 8.3.8 and Solaris 10_x86 64 bit problems?

2009-10-20 Thread Andrew Chernow
I'll hack the makefile and give it a shot. No need to hack it, set CFLAGS during configure: shell]# CFLAGS="-m64" ./configure (options) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] postgres 8.3.8 and Solaris 10_x86 64 bit problems?

2009-10-19 Thread Andrew Chernow
libraries were built as 64-bit using PIC? Are you linking with any static library that may contain 32-bit objects? That error is most commonly PIC or arch-mismatch. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@post

Re: [HACKERS] postgres 8.3.8 and Solaris 10_x86 64 bit problems?

2009-10-19 Thread Andrew Chernow
Zdenek Kotala wrote: Andrew Chernow píše v ne 18. 10. 2009 v 21:09 -0400: I'm curious if this is a lost hope. My boss is recommending we flatten the Sun box and install redhat linux (which I'm fine with). I'd rather not as threading in Solaris is better. Maybe solaris threads

Re: [HACKERS] postgres 8.3.8 and Solaris 10_x86 64 bit problems?

2009-10-18 Thread Andrew Chernow
the case. Any data supporting that argument, solaris 10 threads vs. linux 2.6.11+ kernel (p)threads? Another thing to consider in your decision is that Sun was just bought by oracle, leaving the solaris road map up in the air. At least for me, Linux is a bit more reassuring ... or freebsd. --

Re: [HACKERS] man pages

2009-10-11 Thread Andrew Chernow
David Fetter wrote: Folks, I'd like to see about creating man pages for the following: - libpq - SPI - the built-in functions That would be really helpful and convenient. I've often wanted libpq man pages. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -

Re: [HACKERS] postgres 8.3.8 and Solaris 10_x86 64 bit problems?

2009-10-07 Thread Andrew Chernow
built with the PIC option (gcc -fPIC, sun compiler -Kpic). -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] happy birthday Tom Lane ...

2009-09-18 Thread Andrew Chernow
;) -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] new version of PQconnectdb was:(Re: [HACKERS] Determining client_encoding from client locale)

2009-09-14 Thread Andrew Chernow
d be Daniel San. I was trying to be cute but that apparently failed :( -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] new version of PQconnectdb was:(Re: [HACKERS] Determining client_encoding from client locale)

2009-09-14 Thread Andrew Chernow
Jaime Casanova wrote: On Mon, Sep 14, 2009 at 1:34 PM, Andrew Chernow wrote: Jaime Casanova wrote: i extracted the functions to connect that Heikki put on psql in his patch for determining client_encoding from client locale and put it in libpq so i follow the PQconnectdbParams(* params

Re: [HACKERS] new version of PQconnectdb was:(Re: [HACKERS] Determining client_encoding from client locale)

2009-09-14 Thread Andrew Chernow
tructs floating around, NULL terminated list or include an additional argument specifying element count. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www

Re: [HACKERS] new version of PQconnectdb was:(Re: [HACKERS] Determining client_encoding from client locale)

2009-09-09 Thread Andrew Chernow
nProps); PGconn *PQconnectOptions(const PGoption *options, int nOptions); any one have a preference here? I like the struct approach. I personally prefer specifying the element count of an array, rather than using a NULL terminating element. -- Andrew Chernow eSilo, LLC every bit counts http:

Re: [HACKERS] _WIN32_WINNT should be 0x0501 in win32.h

2009-09-07 Thread Andrew Chernow
Magnus Hagander wrote: On Mon, Sep 7, 2009 at 15:14, Andrew Chernow wrote: Magnus Hagander wrote: On Monday, September 7, 2009, Itagaki Takahiro wrote: We should define _WIN32_WINNT as 0x0500 in src/include/port/win32.h, but it should be 0x0501 (Windows XP) because IPPROTO_IPV6 will be

Re: [HACKERS] _WIN32_WINNT should be 0x0501 in win32.h

2009-09-07 Thread Andrew Chernow
as well. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] New types for transparent encryption

2009-07-07 Thread Andrew Chernow
Andrew Dunstan wrote: Andrew Chernow wrote: Encrypting lots of small chunks of data with the same key is a very dangerous thing to do and it's very tricky to get right. Using an initialization vector (IV) is the way to go, recommend using CBC or CFB mode. Although, an IV is

Re: [HACKERS] New types for transparent encryption

2009-07-07 Thread Andrew Chernow
key; that can leak hints about the plaintext. Where is the randomly generated IV stored for use during decryption? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription:

Re: [HACKERS] [pgsql-www] commitfest.postgresql.org

2009-07-03 Thread Andrew Chernow
de when something occurred was being offered as a solution to know what commitfest it is. I'm not sure where your confusion is? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] [pgsql-www] commitfest.postgresql.org

2009-07-03 Thread Andrew Chernow
st best is to use some kind of key, like 16 random bytes displayed in hex, that looks up the data. IMHO, I don't see much gain to encoding the date into the url either. This is not a great way of telling the user when something occurred. A lookup is going to occur either way, so why not g

Re: [HACKERS] check for missing tablespaces?

2009-05-31 Thread Andrew Chernow
Anyway, from this POV all we really need to know is that the device hosting this tablespace failed to mount when the machine was rebooted, and then postgres restarted. Good to know postgresql had nothing to do with the missing data. I wasn't sure if it was user error, config problem or hard

Re: [HACKERS] check for missing tablespaces?

2009-05-31 Thread Andrew Chernow
this on startup +1 Andrew Chernow -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] check for missing tablespaces?

2009-05-31 Thread Andrew Chernow
this on startup +1 Andrew Chernow -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Keep alive in libpq

2009-05-27 Thread Andrew Chernow
an still be adjusted via WSAIoctl. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] bytea vs. pg_dump

2009-05-06 Thread Andrew Chernow
es text to be broken into 76 char lines but why does encode do this? -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] change oid of a pg_type

2009-04-11 Thread Andrew Chernow
Tom Lane wrote: Andrew Chernow writes: Tom Lane wrote: Merlin Moncure writes: Is there any way to adjust the oid of an already created pg_type No. Then why are oids sent in some type's external binary format? How is that related? Well, the format is called "external&quo

Re: [HACKERS] change oid of a pg_type

2009-04-11 Thread Andrew Chernow
;s name all day long, shouldn't schema.typname be the external way to reference types? Or, perhaps, another mechanism. There are some very powerful things that could be achieved, with a more portable way of referencing types. -- Andrew Chernow eSilo, LLC every bit counts http://www.esi

Re: [HACKERS] Array types

2009-04-08 Thread Andrew Chernow
Andrew Chernow wrote: John Lister wrote: Following this up, is there any docs on the binary wire format for arrays? None that I know of. Check out the backend source: (array_recv() and array_send() functions) http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/arrayfuncs.c

Re: [HACKERS] Array types

2009-04-08 Thread Andrew Chernow
libpqtypes array.c: http://libpqtypes.esilo.com/browse_source.html?file=array.c -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [HACKERS] Array types

2009-04-07 Thread Andrew Chernow
g has proven this. It also reduces the overall coding effort. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Array types

2009-04-07 Thread Andrew Chernow
think you would want to create a JNI wrapper to libpqtypes that converts PGarray to a java array. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org

Re: [HACKERS] PQinitSSL broken in some use casesf

2009-03-30 Thread Andrew Chernow
d a void data pointer argument. The idea was PQinit(which, data, data_len) would be called multiple times to init different things. -- Andrew Chernow eSilo, LLC every bit counts http://www.esilo.com/ -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make chan

Re: [HACKERS] PQinitSSL broken in some use casesf

2009-03-30 Thread Andrew Chernow
Bruce Momjian wrote: It seems having the init function return the bits it recognized would be the logical return value. That's what my first PQionitSecure patch did, actually it returned the bits it didn't understand. -- Andrew Chernow eSilo, LLC every bit counts http://www

  1   2   3   4   >