Re: [SQL] not really SQL but I need info on BLOBs

2004-05-05 Thread Andrei Bintintan
I suggest to store the images on the disc and write in the db only the path. I am using the same solution. The only problem is that I have to make the backups separately(in my case). Also this helps more in accessing the images, you don't have to access for each image the database, you just have to

[SQL] Test - please ignore

2004-05-05 Thread Richard Huxton
Please ignore - testing a previously misconfigured email client -- Richard Huxton Archonet Ltd ---(end of broadcast)--- TIP 6: Have you searched our list archives? http://archives.postgresql.org

Re: [SQL] Rank

2004-05-05 Thread Martin Knipper
Hey, Muhyiddin A.M Hayat sagte: > > Dear All, > > I Have below table > > id | site_name | point > +---+--- > 1 | Site A|40 > 2 | Site B|90 > 3 | Site D|22 > 4 | Site X|98 > > Would like to calc that Rank for each site, and look like > > > >

Re: [SQL] Check a value in array

2004-05-05 Thread Contact AR-SD.NET
select * from table where date in ('02/02/2004', '02/03/2004' ) i'm using pgsql 7.3.2 and it works fine. Andy. - Original Message - From: "Marco Lazzeri" <[EMAIL PROTECTED]> To: "Rod Taylor" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, April 30, 2004 11:18 AM Subject: R

[SQL] COUNT on a DISTINCT query

2004-05-05 Thread Freddy Villalba Arias
Hello everybody,   I’m a newbie to PostgreSQL.   I have the following query:   SELECT DISTINCT (at.*) FROM AGRUPACION_TERRITORIAL at, LINK_AGRUP_TE_MUNICIPIO link, MUNICIPIO m, PROVINCIA p, CCAA c WHERE at.agru_id_agrupacion_t = link.agmu_id_agrupacion_t AND link.agmu

[SQL] not really SQL but I need info on BLOBs

2004-05-05 Thread Theodore Petrosky
Hi, I am starting a new project where I need to store a lot of tiff images. So the question beckons... which is better (not correct)? store a blob in the database and let the db manage the data or store the image in a directory and store the path to the data in the db. What are your opinions? Is

[SQL] Procedure failing after upgrade

2004-05-05 Thread patkins
All, I just upgraded to the latest version from 7.2.x and now a procedure is failing. Please tell me what I'm doing wrong! Original Func: SELECT generateinvoice('{123,124}'); CREATE FUNCTION "generateinvoice" (integer[]) RETURNS integer AS ' DECLARE id_array ALIAS for $1; temp

Re: [SQL] Procedure failing after upgrade

2004-05-05 Thread Rod Taylor
On Tue, 2004-05-04 at 09:32, patkins wrote: > All, > > I just upgraded to the latest version from 7.2.x and now a procedure is failing. > > Please tell me what I'm doing wrong! Please include the actual error message produced. That said, I'm getting an interesting error. It appears as if the int

Re: [SQL] Procedure failing after upgrade

2004-05-05 Thread Tom Lane
Rod Taylor <[EMAIL PROTECTED]> writes: > an interesting error. It appears as if the integer array type is being > confused for a boolean. Up till 7.4, plpgsql's control statements didn't actually check whether the given expression returned boolean :-(. They just assumed that the resulting Datum s

Re: [SQL] Procedure failing after upgrade

2004-05-05 Thread Jie Liang
Are you using 7.4.x now? If so, I think the problem is condition: WHILE id_array[count_it] LOOP Change it to: WHILE id_array[count_it] NOTNULL LOOP Jie Liang -Original Message- From: patkins [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 04, 2004 6:32 AM To: [EMAIL PROTECTE