[SQL] Max Conncection limit?

2001-03-12 Thread Najm Hashmi
We start a server and initiate 30 connections(with the libpq C interface) which are stored in a stack to use and and to be reused. After awhile I try to start another server that will also try to initiate 30 connections, for each connection I then get a PQErrorMessage like that : "Sorry, too

Re: [SQL] Max Conncection limit?

2001-03-12 Thread Frank Joerdens
On Tue, Mar 13, 2001 at 11:33:10AM -0500, Najm Hashmi wrote: We start a server and initiate 30 connections(with the libpq C interface) which are stored in a stack to use and and to be reused. After awhile I try to start another server that will also try to initiate 30 connections, for

Re: [SQL] Comparing dates

2001-03-12 Thread David Lynn
Hello - It seems that using BETWEEN would work well, especially for finding dates between two other dates. WHERE date_date BETWEEN '03-02-2001'::date and '03-03-2001'::date --d On Tue, 6 Mar 2001, Markus Fischer wrote: Hello, I've a SELECT statement on many joined Tabled and one of

[SQL] Poor document!!

2001-03-12 Thread Noodle
I cannot believe that PostgreSQL has a so poor document, I cannot found any useful information. I afraid I have to select MySQL. Does anybody know if PostgreSQL support Unicode and Full-Text Index? I couldn't found any information about these from http://www.postgresql.org! Thanks Noodle

[SQL] default value syntax - pg compared to?

2001-03-12 Thread Emils Klotins
Hello, do you happen to know, if there is any sqlserver that WON'T handle inserting default value if it is not specified in the INSERT field list? I am particularly interested in ORACLE, INFORMIX and MYSQL . Eg. CREATE TABLE test ( id integer default 5, fld1 text ); INSERT

[SQL] SQL problem

2001-03-12 Thread Salvador Mainé
Hello: I have a table with pluviometrical data meteo (rain float, day date) I want to select the the day of maximum value for each year.It should be something like : select max(rain),day from meteo group by date_part('year', day); but it obiously doesn't work. I thought of doing it with

[SQL] Re: SQL problem

2001-03-12 Thread Kevin T. Manley \(Home\)
Here's one approach: create view vw_maxrain as select max(rain) as rain, date_part('year',day) as year from meteo group by year; select day, meteo.rain from meteo, vw_maxrain where meteo.rain=vw_maxrain.rain; "Salvador Mainé" [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL

[SQL] Re: [DOCS] Extending PostgreSQL Using C

2001-03-12 Thread Nishad Prakash
On Wed, 7 Mar 2001, Tom Lane wrote: Hannu Krosing [EMAIL PROTECTED] writes: Boulat Khakimov wrote: ERROR: Can't find function encrypt in file /[full path here]/encrypt.so Can _postgres_ user read /[full path here]/encrypt.so ? Presumably so. If he were unable to load the .so file,

[SQL] help

2001-03-12 Thread chard
help me pls. i got an error like this when i do an insert to a table, my table dont have bpchar type of field. ERROR: Unable to identify an operator '=' for types 'bpchar' and 'varchar' You will have to retype this query using an explicit cast ---(end of

[SQL] Re: [DOCS] Extending PostgreSQL Using C

2001-03-12 Thread Hannu Krosing
Boulat Khakimov wrote: Hi, Im writing a C function for PG to do one way encryption using crypt. Here is the source code it gives me this error ERROR: Can't find function encrypt in file /[full path here]/encrypt.so Why do I get this error Any ideas? Can _postgres_ user

Re: [SQL] default value syntax - pg compared to?

2001-03-12 Thread Josh Berkus
Emils, do you happen to know, if there is any sqlserver that WON'T handle inserting default value if it is not specified in the INSERT field list? I am particularly interested in ORACLE, INFORMIX and MYSQL . MS SQL 6.5, 7.0 and 2000 all support default values on incremental fields ... with

[SQL] I need an aggregate with 2 parameters

2001-03-12 Thread Salvador Mainé
Hello: I have a table with pluviometrical data meteo (rain float, day date, oid station) I want to select the the day of maximum value for each year for a given measurement station. It should look like : select max(rain),day from meteo group by date_part('year', day) where station=7654765;

[SQL] ecpg on 7.0

2001-03-12 Thread Jia L Han
Hi, I installed postgresql 7.0 from RedHat CD. According to the official 7.0 doc, ecpg comes with the installation. However, I could not find ecpg (by searching directories and using whereis). I also cannot find doc on how to invoke ecpg. The postgresql seems OK. I can initdb,

Re: [SQL] I need an aggregate with 2 parameters

2001-03-12 Thread Michael Fork
This should work: SELECT day, rain FROM meteo WHERE rain = (SELECT max(rain) FROM meteo WHERE date_part('year', day) = '2001') Michael Fork - CCNA - MCP - A+ Network Support - Toledo Internet Access - Toledo Ohio On Thu, 8 Mar 2001, Salvador [iso-8859-1] Mainé wrote: Hello: I have a table

Re: [SQL] help

2001-03-12 Thread Stephan Szabo
What is the schema of the table in question, does it have any references to other tables and what is an example insert statement? On Wed, 7 Mar 2001, chard wrote: help me pls. i got an error like this when i do an insert to a table, my table dont have bpchar type of field. ERROR:

Re: [SQL] help

2001-03-12 Thread Tom Lane
chard [EMAIL PROTECTED] writes: i got an error like this when i do an insert to a table, my table dont have bpchar type of field. ERROR: Unable to identify an operator '=' for types 'bpchar' and 'varchar' You will have to retype this query using an explicit cast it seems 1 field in

Re: [SQL] Re: [GENERAL] MySQLs Describe emulator!

2001-03-12 Thread Patrick Welche
On Tue, Mar 06, 2001 at 10:38:43AM -0500, Michael Fork wrote: try starting psql with the -E option -- this displays all queries used internally to the screen, i.e.: Sorry, hadn't read this one before posting... Thanks to the "moderating" it'll all be out of synch anyway but.. Patrick

Re: [SQL] How does this query work.....?

2001-03-12 Thread Stephan Szabo
pg_class holds the relation information (tables, etc) pg_attribute holds attribute information (attname), it keeps the oid of the relation it's on in attrelid and the oid of the type as atttypid pg_type holds type information (typname) The attnum0 is to limit the check to user attributes.

[ADMIN] Re: Use of the LIMIT clause ?

2001-03-12 Thread Tom Lane
Spy [EMAIL PROTECTED] writes: Tom Lane a écrit : Is that actually how MySQL interprets two parameters? We treat them as count and offset respectively, which definition I thought was the same as MySQL's. But MySQL's syntax is different, as found on http://www.mysql.com/doc/S/E/SELECT.html

Re: [SQL] SQL Dummy Needs Help

2001-03-12 Thread Cliff Crawford
* Cliff Crawford [EMAIL PROTECTED] menulis: SELECT table2.title_no, table2.paidto_date FROM table1, table2 WHERE table1.title_no=table2.title_no AND (date_part('month', table1.effect_date) != date_part('month', table2.paidto_date) OR date_part('day',