pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Stephan Szabo <sszabo@kick.com>
To: Alex <gliathit@ihug.com.au>
Cc: pgsql-sql@postgresql.org
Subject: Re: Re: Simple search question
Date: Thu, 15 Jun 2000 12:09:39 -0700
Message-ID: <00d801bfd6fd$41344dc0$0c64010a@kick.com> (raw)
References: <39457549.CEA07C63@ihug.com.au>
	<slrn8kb2dm.3rr.newsuser@linux2.johnmckown.net>
	<39459935.CCCEFDAA@ihug.com.au>
	<87hfaxkelm.fsf@ptdixon.globalnet.co.uk>
	<39487DD3.7F2BBAE1@ihug.com.au>

> This brings me back to another unanswered question recently posted
up,maybe
> it is impossible...
> I declared a new table with one of the types as serial (which is really
just a
> sort of macro I believe, which automates the creation of a few things for
your
> convenience), which initialises the last_value of the relation (the
sequence
> itself), as 1. Therefore, upon INSERTing my first row, the serial number
began
> at 1, next was 2, then 3, and so forth.
>  My question is, is it possible to alter the sequence last_value column,
as
> I need the serial number to begin from 1000?

select setval(sequencename, value); should set the sequence as if value was
the last value given out in the sequence.





view thread (10+ messages)  latest in thread

Message-ID: <00d801bfd6fd$41344dc0$0c64010a@kick.com>
Permalink:  ../00d801bfd6fd$41344dc0$0c64010a@kick.com/
Also on:    postgresql.org/message-id/00d801bfd6fd$41344dc0$0c64010a@kick.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: sszabo@kick.com, gliathit@ihug.com.au
  Subject: Re: Simple search question
  In-Reply-To: <00d801bfd6fd$41344dc0$0c64010a@kick.com>
  References: <39457549.CEA07C63@ihug.com.au> <slrn8kb2dm.3rr.newsuser@linux2.johnmckown.net> <39459935.CCCEFDAA@ihug.com.au> <87hfaxkelm.fsf@ptdixon.globalnet.co.uk> <39487DD3.7F2BBAE1@ihug.com.au> <00d801bfd6fd$41344dc0$0c64010a@kick.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox