START for SERIAL type?
START for SERIAL type?
От:
jferry@iexposure.com
Дата:
When you create a SEQUENCE, you are allowed to specify a START. Is there a way to specify a START if you use a serial type in a CREATE TABLE statement? I'm envisioning something like: CREATE TABLE foo ( foo_id serial ( 101 ) );
Re: START for SERIAL type?
От:
Vivek Khera <khera@kcilink.com>
Дата:
>>>>> "j" == jferry writes: j> When you create a SEQUENCE, you are allowed to specify a START. Is j> there a way to specify a START if you use a serial type in a CREATE j> TABLE statement? No. You do it after you create the table. The SERIAL type creates a sequence, so just use the sequence command setval() to set the starting value for the named sequence. -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Vivek Khera, Ph.D. Khera Communications, Inc. Internet: khera@kciLink.com Rockville, MD +1-240-453-8497 AIM: vivekkhera Y!: vivek_khera http://www.khera.org/~vivek/
Re: START for SERIAL type?
От:
"Frank Contrepois" <sokak@tin.it>
Дата:
read the doc section datatype!!! serial just create a sequence on a standard way, if you dont like it you'll have to create your sequence. bye -- -- "L'idea di base � estremamente semplice..." �opyright Frank "Pazzooo" Contrepois (schiavista francese del '900)