BUG #6617: FETCH FIRST syntax accepts only constants and not parameters - Mailing list pgsql-bugs

From dodobas@geoinfo.geof.hr
Subject BUG #6617: FETCH FIRST syntax accepts only constants and not parameters
Date
Msg-id E1SNR9B-0001iZ-OE@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #6617: FETCH FIRST syntax accepts only constants and not parameters  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      6617
Logged by:          Dra=C5=BEen Odoba=C5=A1i=C4=87
Email address:      dodobas@geoinfo.geof.hr
PostgreSQL version: 9.1.3
Operating system:   Linux 3.3.3
Description:=20=20=20=20=20=20=20=20

When tried setting FETCH FIRST parameter dynamically in RETURN QUERY EXECUTE
some_query USING param1 it resulted with a syntax error on FETCH FIRST
parameter.

Apparently, it only accepts constants so it works with ($1)=20

Bug example: https://pgsql.privatepaste.com/1e3ef786a5

pgsql-bugs by date:

Previous
From: Ryan Kelly
Date:
Subject: ALTER TABLE ... OWNER TO does not change ownership recursively
Next
From: "Kevin Grittner"
Date:
Subject: Re: BUG #6617: FETCH FIRST syntax accepts only constants and not parameters