[GENERAL] Documentation - PgAdmin

2009-07-04 Thread db . subscriptions

Hi,

Congratulations on the release of version 8.4.

I am surprised that pgAdmin's help link is now directed to the  
documentation website of postgresql. The embedded help CHM was not  
packaged with it.


This implies that anytime one needs help on a simple syntax, one must  
connect to the internet.


Was this by design or omission?

Regards,
Chris

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Loop

2009-09-11 Thread db . subscriptions

Hi,

I have a loop of the form:

	FOR rec IN SELECT code FROM staff WHERE shiftgroup = NEW.groupe ORDER  
BY code LOOP

WHILE sdate <= NEW.todate LOOP
			SELECT INTO starty,endy,nday resumetime,closetime,nextday FROM  
shifts WHERE shift = NEW.shift;

restime := sdate + starty;

IF nday = true THEN
clstime := sdate + interval '1 day' + endy;
ELSE
clstime := sdate + endy;
END IF;

			INSERT INTO shiftsexp(id,staff,resumetime,closetime)  
VALUES(NEW.id,rec.code,restime,clstime);

sdate := sdate + interval '1 day';
END LOOP;
END LOOP;

Surprisingly, the outer loop (For .. Loop) does not loop while only  
the WHILE ... Loop works.


Any hint would be appreciated.

Regards,
Chris.

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] PostgreSQL Installation

2010-02-11 Thread db . subscriptions

Hi,

Please why is it that we must register at EnterpriseDB and register  
each Windows installation of postgreSQL these days?


At times, I need to install on a server that is not on the internet  
and have had to bear the pain of configuring a server for internet  
before I can install postgreSQL.


Please can't we bypass this or better still, we have a binary that has  
no 'strings' attached?


Please let me know.

Chris.



--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] PostgreSQL Installation

2010-02-11 Thread db . subscriptions

Thanks.

I think I mistook postgres for postgres-plus.

Quoting Ashesh Vashi :


You can always download PostgreSQL installer for any supported platform
without any registration from
http://www.enterprisedb.com/products/pgdownload.do.


On Thu, Feb 11, 2010 at 4:30 PM,  wrote:


Hi,

Please why is it that we must register at EnterpriseDB and register each
Windows installation of postgreSQL these days?

At times, I need to install on a server that is not on the internet and
have had to bear the pain of configuring a server for internet before I can
install postgreSQL.

Please can't we bypass this or better still, we have a binary that has no
'strings' attached?

Please let me know.

Chris.



--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general







--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Serial Jumping

2009-01-26 Thread db . subscriptions

Hi,

I have a table with BIG SERIAL field as Primary KEY. During high load,
entries in the BIG SERIAL field are jumped. One could see a row with
1367 and expecting the next INSERT to be 1368, one would end up
getting 1369.

Please is this normal?

Regards,
Chris

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Create User

2006-01-20 Thread DB Subscriptions

Hi,

I have this table:

CREATE TABLE users
(
 userid varchar(100) NOT NULL,
 nama varchar(50) NOT NULL,
 pword varchar(255) NOT NULL,
 groupe varchar(7) NOT NULL,
 rolle int2 NOT NULL DEFAULT 2,
 statux varchar(9) NOT NULL DEFAULT 'Active'::character varying,
 CONSTRAINT users_pkey PRIMARY KEY (userid)
)
WITHOUT OIDS;

I created a trigger to create a user based on the new insert into the 
table as follows:


CREATE OR REPLACE FUNCTION users_insert()
 RETURNS "trigger" AS
$BODY$
BEGIN
   CREATE USER NEW.userid WITH PASSWORD NEW.pword IN GROUP NEW.groupe;
 
   RETURN new;

END;

$BODY$
 LANGUAGE 'plpgsql' VOLATILE;

Surprisingly, I get this error message:

ERROR:  syntax error at or near "$1" at character 14
QUERY:  CREATE USER  $1  WITH PASSWORD  $2  IN GROUP  $3
CONTEXT:  SQL statement in PL/PgSQL function "users_insert" near line 10

I would appreciate your guidance.

Cheers.

Chris.



___ 
Yahoo! Photos – NEW, now offering a quality print service from just 8p a photo http://uk.photos.yahoo.com


---(end of broadcast)---
TIP 4: Have you searched our list archives?

  http://archives.postgresql.org


Re: [GENERAL] Create User

2006-01-20 Thread DB Subscriptions

Thanks Pandurangan.

The Function could not even be saved or created. The error is not at the 
insert level but at the creation of the trigger function.


Regards.


Pandurangan R S wrote:


I hope this error arises when you do a insert.
Can u post your insert statement that caused this error?

On 1/20/06, DB Subscriptions <[EMAIL PROTECTED]> wrote:
 


Hi,

I have this table:

CREATE TABLE users
(
 userid varchar(100) NOT NULL,
 nama varchar(50) NOT NULL,
 pword varchar(255) NOT NULL,
 groupe varchar(7) NOT NULL,
 rolle int2 NOT NULL DEFAULT 2,
 statux varchar(9) NOT NULL DEFAULT 'Active'::character varying,
 CONSTRAINT users_pkey PRIMARY KEY (userid)
)
WITHOUT OIDS;

I created a trigger to create a user based on the new insert into the
table as follows:

CREATE OR REPLACE FUNCTION users_insert()
 RETURNS "trigger" AS
$BODY$
BEGIN
   CREATE USER NEW.userid WITH PASSWORD NEW.pword IN GROUP NEW.groupe;

   RETURN new;
END;

$BODY$
 LANGUAGE 'plpgsql' VOLATILE;

Surprisingly, I get this error message:

ERROR:  syntax error at or near "$1" at character 14
QUERY:  CREATE USER  $1  WITH PASSWORD  $2  IN GROUP  $3
CONTEXT:  SQL statement in PL/PgSQL function "users_insert" near line 10

I would appreciate your guidance.

Cheers.

Chris.



___
Yahoo! Photos – NEW, now offering a quality print service from just 8p a photo 
http://uk.photos.yahoo.com

---(end of broadcast)---
TIP 4: Have you searched our list archives?

  http://archives.postgresql.org

   





___ 
To help you stay safe and secure online, we've developed the all new Yahoo! Security Centre. http://uk.security.yahoo.com


---(end of broadcast)---
TIP 1: if posting/reading through Usenet, please send an appropriate
  subscribe-nomail command to [EMAIL PROTECTED] so that your
  message can get through to the mailing list cleanly


[GENERAL] [ANN] PostgreSqlClient 2.0 Beta 1 released.

2006-04-08 Thread DB Subscriptions

PostgreSqlClient ( old PgSqlClient ) 2.0 Beta 1 is available for download.

It's the first version for ADO.NET 2.0 and Microsoft .NET 2.0, be aware 
that right now it doesn't provide integration with Visual Studio 2005.


Download information can be found:

http://sourceforge.net/project/showfiles.php?group_id=85397


Provider Home Page:

http://pgsqlclient.sourceforge.net/


Best Regards

Chris.


___ 
To help you stay safe and secure online, we've developed the all new Yahoo! Security Centre. http://uk.security.yahoo.com


---(end of broadcast)---
TIP 2: Don't 'kill -9' the postmaster


[GENERAL] Query Cost

2005-09-18 Thread ShepherdHill DB Subscriptions
Hi,

I have a table with this schema:

CREATE TABLE billing.bill
(
  sno serial NOT NULL,
  billno int4,
  det date NOT NULL,
 .
 .
 .
  CONSTRAINT bill_pkey PRIMARY KEY (sno)
)

I want to execute a query that will not return any record. Which of
these queries is cheaper please?

1.   Select * from billing.bill where 1=0
2.   Select * from billing.bill where sno=0

Thanks for your assistance.

Chris.

---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings


[GENERAL] Replicator

2005-09-18 Thread ShepherdHill DB Subscriptions
Hi,

Does anyone know of any open source PostgreSQL replicator that can
replicate data from Fedora Core4 to Windows Server? Can Slony do that?

Thanks for your advice.

Best regards.

Chris.

---(end of broadcast)---
TIP 1: if posting/reading through Usenet, please send an appropriate
   subscribe-nomail command to [EMAIL PROTECTED] so that your
   message can get through to the mailing list cleanly


[GENERAL] Validating User

2005-12-28 Thread ShepherdHill DB Subscriptions
Hi,

Please as a superuser how would I obtain an equivalent of this query:

SELECT * FROM pg_shadow WHERE usename='userid' AND md5(passwd)='passwd'

I browse the content of the pg_shadow and the passwd field shows
something like md5...

All I am after is to validate a user against pg_shadow table in version
8.0.4.

Cheers.

Olu

---(end of broadcast)---
TIP 9: In versions below 8.0, the planner will ignore your desire to
   choose an index scan if your joining column's datatypes do not
   match