Re: replacing expresion in plpgsql

From: Andreas Brandl <ml(at)3(dot)141592654(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: replacing expresion in plpgsql
Date: 2013-12-16 01:02:18
Message-ID: a2d09450-fa89-4296-8395-6dc251885580@store1.zcs.ext.wpsrv.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

John,

----- Ursprüngliche Mail -----
> On 12/15/2013 4:17 PM, Andreas Brandl wrote:
> > select current_timestamp, current_timestamp + interval '2' day;
>
> that should be interval '2 day' (note the ' moved), and for a
> variable number passed as a parameter, try...

# select current_timestamp + interval '2' day;
# select current_timestamp + interval '2' minute;

all valid, but seems to only work in SQL (and not plpgsql) context.

Regards,
Andreas

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Juan Pablo L 2013-12-16 01:09:18 Re: replacing expresion in plpgsql
Previous Message Juan Pablo L 2013-12-16 00:53:53 Re: replacing expresion in plpgsql