Re: Sequence Current Value Resetting

From: John DeSoi <desoi(at)pgedit(dot)com>
To: Douglas Doolittle <DDoolittle(at)nbbc(dot)edu>
Cc: "pgsql-novice(at)postgresql(dot)org List" <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Sequence Current Value Resetting
Date: 2006-04-11 23:53:53
Message-ID: 97BC905B-8E71-465B-9B40-B8DEC18672F5@pgedit.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

(be sure to copy the list so others can see your message and offer help)

What you have looks OK to me in that ClassID is not inserted and thus
should get the next sequence value on the insert.

If there is no other code or operation that inserts or updates the
table, I'm out of ideas.

On Apr 11, 2006, at 2:35 PM, Douglas Doolittle wrote:

> We are using an Access front-end. The ClassID is the primary key for
> each record and that is being provided by the sequence. Below is the
> query that I ran. This is identical to what I ran in August other
> than
> the SemesterIDs were different.
>
> Fall 2005 - 96
> Fall 2006 - 114
>
> qry2659 (276 Records)
> ---
> INSERT INTO tblclass ( classinfolink, [section], stafflink,
> stafflink2,
> semesterlink, maxnum, location, startdate, enddate, block, labfee,
> notes, [hour], dayofweek, gbprogram, gbdirectory, cuts )
> SELECT tblclass.classinfolink, tblclass.section, tblclass.stafflink,
> tblclass.stafflink2, 114 AS SemLink, tblclass.maxnum,
> tblclass.location,
> tblclass.startdate, tblclass.enddate, tblclass.block, tblclass.labfee,
> tblclass.notes, tblclass.hour, tblclass.dayofweek, tblclass.gbprogram,
> tblclass.gbdirectory, tblclass.cuts
> FROM tblclass
> WHERE (((tblclass.semesterlink)=96));

John DeSoi, Ph.D.
http://pgedit.com/
Power Tools for PostgreSQL

Browse pgsql-novice by date

  From Date Subject
Next Message Sean McCune 2006-04-12 00:33:33 Re: PostgreSQL a slow DB?
Previous Message Alasdair Young 2006-04-11 23:50:26 Re: Indexes slower when used in decending vs. ascending order?