Skip site navigation (1) Skip section navigation (2)

Re: BUG #2773: Problem pg_get_serial_sequence

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Amelio <ameliocf(at)yahoo(dot)com(dot)br>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2773: Problem pg_get_serial_sequence
Date: 2006-11-21 17:08:06
Message-ID: 200611211708.kALH86N03282@momjian.us (view raw or flat)
Thread:
Lists: pgsql-bugs
Amelio wrote:
> 
> The following bug has been logged online:
> 
> Bug reference:      2773
> Logged by:          Amelio
> Email address:      ameliocf(at)yahoo(dot)com(dot)br
> PostgreSQL version: 8.2 beta 2
> Operating system:   Windows XP
> Description:        Problem pg_get_serial_sequence
> Details: 
> 
> The pg_get_serial_sequence function is returning the name of the index on
> the referenced column.

Can you provide a reproducible test case?  It looks OK to me:

	test=> CREATE TABLE test (x SERIAL);
	NOTICE:  CREATE TABLE will create implicit sequence "test_x_seq" for
	serial column "test.x"
	CREATE TABLE

	test=> SELECT pg_get_serial_sequence('test', 'x');
	 pg_get_serial_sequence
	------------------------
	 public.test_x_seq
	(1 row)
	
	test=> CREATE INDEX i_test ON test(x);
	CREATE INDEX

	test=> SELECT pg_get_serial_sequence('test', 'x');
	 pg_get_serial_sequence
	------------------------
	 public.test_x_seq
	(1 row)

-- 
  Bruce Momjian   bruce(at)momjian(dot)us
  EnterpriseDB    http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

In response to

Responses

pgsql-bugs by date

Next:From: Stefan KaltenbrunnerDate: 2006-11-21 17:13:44
Subject: Re: BUG #2773: Problem pg_get_serial_sequence
Previous:From: rahman suleDate: 2006-11-21 16:28:18
Subject: PGSQL SETUP PROBLEM

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group