Re: I'm very confused.

From: Ray Stell <stellr(at)cns(dot)vt(dot)edu>
To: Brant Fitzsimmons <brant(at)bfcomputerconsulting(dot)com>
Cc: Sean Davis <sdavis2(at)mail(dot)nih(dot)gov>, pgsql-novice(at)postgresql(dot)org, Jasbinder Singh Bali <jsbali(at)gmail(dot)com>
Subject: Re: I'm very confused.
Date: 2007-01-17 15:53:02
Message-ID: 20070117155302.GA10549@cns.vt.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice


Please consider the archives when choosing a Subject line.

On Wed, Jan 17, 2007 at 10:10:47AM -0500, Brant Fitzsimmons wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Sean Davis wrote:
> > On Wednesday 17 January 2007 09:54, Brant Fitzsimmons wrote:
> >> Sean Davis wrote:
> >>> On Wednesday 17 January 2007 03:06, Brant Fitzsimmons wrote:
> >>>> Jasbinder Singh Bali wrote:
> >>>>> Please attach a snippet of your python script and lets see
> >>>>> what are you doing there. That might make things easy. Jas
> >>>> Here is the entire test script:
> >>>>
> >>>> #!/usr/bin/python
> >>>>
> >>>> # import pgdb module import pgdb
> >>>>
> >>>> # connect to the db db = pgdb.connect(host="localhost",
> >>>> database="test", user="postgres", password="**********")
> >>>>
> >>>> # instantiate cursor cursor = db.cursor()
> >>>>
> >>>> # insert 10 records for x in range(10):
> >>>> cursor.execute("INSERT INTO users (username, firstname,
> >>>> lastname, email, age) VALUES ('brant', 'Brant',
> >>>> 'Fitzsimmons', 'brant(at)bfcomputerconsulting(dot)com', 31)")
> >>> Put in a db.commit() statement here. Does that fix your
> >>> problem?
> >> It sure does. Any idea why it would drive up the serial column
> >> even though nothing was committed?
> >
> > Great to hear....
> >
> > A serial column is a macro to make a sequence and then to fill the
> > column with the default "next_val" from the sequence. The mere
> > selection of next_val increases the sequence, which is necessary to
> > ensure that all connections get a unique value when selecting from
> > the same sequence.
> >
> > Sean
>
> I see.
>
> Thanks for your help and thanks to everyone who contributed ideas.
> The quick response was unexpected and very encouraging.
>
> - --
> Brant Fitzsimmons
> brant(at)bfcomputerconsulting(dot)com
> - -------------------------------------------------------------------
> "Strange times are these in which we live when the old and the
> young are taught falsehoods in the schools of learning. And the one
> man that dares to tell the truth is called at once a lunatic and
> a fool."
> -Plato
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.3 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFFrjx3Dpzwx2t8E5gRAip+AJ9QXHE1ft+CcAn1lDvMeNY7r7xMqwCgknw5
> 9IhV0WJwhzg8m1Ss21cEbY0=
> =te1Z
> -----END PGP SIGNATURE-----
>

--
You have no chance to survive make your time.

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message joe speigle 2007-01-17 16:19:01 COMMENT on "osc_zones" ...... ERROR at the opening quotation
Previous Message Brant Fitzsimmons 2007-01-17 15:10:47 Re: I'm very confused.