Re: [HACKERS] [PATCHES] New variable server_version_num

2006-08-12 Thread Bruce Momjian
David Fetter wrote: On Sat, Jul 29, 2006 at 09:14:16PM -0400, Greg Sabino Mullane wrote: Today on IRC David Fetter and some others were discussing version numbers and we realized that although libpq now provides the version of Postgres as a number, this is still a wheel that is being

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-08-11 Thread David Fetter
On Sat, Jul 29, 2006 at 09:14:16PM -0400, Greg Sabino Mullane wrote: Today on IRC David Fetter and some others were discussing version numbers and we realized that although libpq now provides the version of Postgres as a number, this is still a wheel that is being reinvented by apps many times

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-08-01 Thread Jim C. Nasby
On Sun, Jul 30, 2006 at 11:27:33AM -0400, Tom Lane wrote: David Fetter [EMAIL PROTECTED] writes: On Sat, Jul 29, 2006 at 09:44:10PM -0400, Tom Lane wrote: The correct solution is for client-side libraries to provide the feature. Not if the app is written in SQL, as the bootstrap,

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-08-01 Thread David Fetter
On Tue, Aug 01, 2006 at 12:37:48PM -0500, Jim C. Nasby wrote: On Sun, Jul 30, 2006 at 11:27:33AM -0400, Tom Lane wrote: David Fetter [EMAIL PROTECTED] writes: On Sat, Jul 29, 2006 at 09:44:10PM -0400, Tom Lane wrote: The correct solution is for client-side libraries to provide the

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-30 Thread David Fetter
On Sat, Jul 29, 2006 at 09:44:10PM -0400, Tom Lane wrote: Greg Sabino Mullane [EMAIL PROTECTED] writes: small patch to provide a new variable server_version_num, which is almost the same as server_version but uses the handy PG_VERSION_NUM which allows apps to do things like if ($version =

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-30 Thread Tom Lane
David Fetter [EMAIL PROTECTED] writes: On Sat, Jul 29, 2006 at 09:44:10PM -0400, Tom Lane wrote: The correct solution is for client-side libraries to provide the feature. Not if the app is written in SQL, as the bootstrap, regression test, etc. code for modules frequently is. SQL doesn't

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-30 Thread David Fetter
On Sun, Jul 30, 2006 at 11:27:33AM -0400, Tom Lane wrote: David Fetter [EMAIL PROTECTED] writes: On Sat, Jul 29, 2006 at 09:44:10PM -0400, Tom Lane wrote: The correct solution is for client-side libraries to provide the feature. Not if the app is written in SQL, as the bootstrap,

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-30 Thread Jonah H. Harris
On 7/30/06, David Fetter [EMAIL PROTECTED] wrote: Failure to parse means the transaction bails out, which is just what I want in my case, as it disallows people attempting to run the programs--they're for DBI-Link--on too early a version of PostgreSQL. As there are some subtleties to the

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-30 Thread David Fetter
On Sun, Jul 30, 2006 at 12:17:57PM -0400, Jonah H. Harris wrote: On 7/30/06, David Fetter [EMAIL PROTECTED] wrote: Failure to parse means the transaction bails out, which is just what I want in my case, as it disallows people attempting to run the programs--they're for DBI-Link--on too early a

Re: [HACKERS] [PATCHES] New variable server_version_num

2006-07-29 Thread Tom Lane
Greg Sabino Mullane [EMAIL PROTECTED] writes: small patch to provide a new variable server_version_num, which is almost the same as server_version but uses the handy PG_VERSION_NUM which allows apps to do things like if ($version = 80200) without having to parse apart the value of