Re: [SQL] Nextval & Currval

2008-06-10 Thread Scott Marlowe
On Tue, Jun 10, 2008 at 7:14 AM, Shavonne Marietta Wijesinghe <[EMAIL PROTECTED]> wrote: > I managed to make the connection work. I tried inserting records from 2 > computers. It works fine untill 2 computers insert a nextwall one after > another. > > Here is a small example of what i see in my DB

Re: [SQL] Nextval & Currval

2008-06-10 Thread Shavonne Marietta Wijesinghe
I managed to make the connection work. I tried inserting records from 2 computers. It works fine untill 2 computers insert a nextwall one after another. Here is a small example of what i see in my DB ++|+|++ N °| Session| Number +

Re: [SQL] Nextval & Currval

2008-06-10 Thread Shavonne Marietta Wijesinghe
This is the test i did for the connection. ' Connecting to the database WriteToFile logfilepath, date & " " & time & "isobject(conn) = " & isobject(session("connection")) & vbcrlf , True if not isobject(session("connection")) then Set conn = Server.CreateObject("ADODB.Connection") conn.Op

Re: [SQL] Nextval & Currval

2008-06-10 Thread A. Kretschmer
am Tue, dem 10.06.2008, um 11:56:39 +0200 mailte Shavonne Marietta Wijesinghe folgendes: > Hello > > I'm using Nextval and Currval in my ASP programme. But everytime i run the > code > only the nextval record is inserted and the currval record is lost. I wrote > the > INSERT INTO in the log a

[SQL] Nextval & Currval

2008-06-10 Thread Shavonne Marietta Wijesinghe
Hello I'm using Nextval and Currval in my ASP programme. But everytime i run the code only the nextval record is inserted and the currval record is lost. I wrote the INSERT INTO in the log and when i tried it via pgadmin both the records were inserted correctly, so there is no syntax error. I

Re: [SQL] nextval problem

2004-02-17 Thread Greg Patnude
New feature for posgreSQL 7.3 & later -- sequences are automatically dropped when the owning table is dropped -- you need to recreate the sequence The easiest way is in your CREATE TABLE tblName ( id serial PRIMARY KEY, blah..., blah..., ) WITH OIDS; -- Greg Patnude / The Digit

[SQL] nextval problem

2004-02-15 Thread Ivo Anon
I'm new to postgresql and I'm having problems with the 'nextval' function (or whatever it is called in postgresql). I created a table (called ADDRESS) using 'pgadmin' which has a serial field (called addressid). When I tried the sql statement: select nextval('public."ADDRESS_addressid_seq

[SQL] nextval...

2002-08-28 Thread friedrich nietzsche
Ok , now I believe it :) thanks to all. danilo __ Yahoo! Musica: notizie, recensioni, classifiche, speciali multimediali http://it.yahoo.com/mail_it/foot/?http://it.music.yahoo.com/ ---(end of broadcast)

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-24 Thread Henry House
On Fri, Jul 20, 2001 at 10:13:04AM -0700, Dado Feigenblatt wrote: [...] > You kind of implied the answer to my question. > You just does it in the client instead of using back stored > functions/triggers or contrived SQL to handle that, right? That's correct. -- Henry House OpenPGP key availab

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread David Stanaway
Have you looked at the serial type? This type creates an explicity sequence with a predictable name: tblname_rowname_seq and has a default value that selects the next val from that sequence. You can get the value of the most recently inserted row in your session with CurrVal('tblname_rowname_se

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread Dado Feigenblatt
Josh Berkus wrote: > Dado, > > Maybe we're looking at this the hard way. Have you thought of simply > putting in a DATETIME column and sorting by that? > > -Josh > Sorting? I might have expressed myself wrong. I'm not concerned about sorting. I'm concerned about giving rows in a single table an

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread Josh Berkus
Dado, Maybe we're looking at this the hard way. Have you thought of simply putting in a DATETIME column and sorting by that? -Josh __AGLIO DATABASE SOLUTIONS___ Josh Berkus Complete information technology [EMAIL PROTECTE

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread Dado Feigenblatt
Henry House wrote: >On Thu, Jul 19, 2001 at 07:17:20PM -0700, Dado Feigenblatt wrote: > >>I'm not sure if I worded the subject right, but my problem is this: >> >>I have a few entries in one table. Each row is the parent of many >>entries in a second table. >>In the second table I have a lot of

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread Dado Feigenblatt
Josh Berkus wrote: >Dado, > >>I'm not sure if I worded the subject right, but my problem is this: >> >>I have a few entries in one table. Each row is the parent of many >>entries in a second table. >>In the second table I have a lot of entries referencing the entries >>on >>the first table. >>S

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-20 Thread Henry House
On Thu, Jul 19, 2001 at 07:17:20PM -0700, Dado Feigenblatt wrote: > I'm not sure if I worded the subject right, but my problem is this: > > I have a few entries in one table. Each row is the parent of many > entries in a second table. > In the second table I have a lot of entries referencing the

Re: [SQL] nextval on insert by arbitrary sequence

2001-07-19 Thread Josh Berkus
Dado, > I'm not sure if I worded the subject right, but my problem is this: > > I have a few entries in one table. Each row is the parent of many > entries in a second table. > In the second table I have a lot of entries referencing the entries > on > the first table. > So far so good. Basic f

[SQL] nextval on insert by arbitrary sequence

2001-07-19 Thread Dado Feigenblatt
I'm not sure if I worded the subject right, but my problem is this: I have a few entries in one table. Each row is the parent of many entries in a second table. In the second table I have a lot of entries referencing the entries on the first table. So far so good. Basic foreign key thing. The