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

Re: arrays and functions in plpgsql

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Todd Kover <kovert(at)omniscient(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: arrays and functions in plpgsql
Date: 2004-09-18 00:10:48
Message-ID: 26819.1095466248@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-novice
Todd Kover <kovert(at)omniscient(dot)com> writes:
>         v_state[3] float8;

Hmm.  I'm not sure what the plpgsql parser will make of that.  I think
you probably wanted
          v_state float8[3];

(note that you really want [4], not that it actually matters since PG
doesn't enforce the array size; float8[] would do as well)

Also, I think you need to change v_state to v_old_state in several more
places than you did, or else assign v_old_state to v_state up front.

			regards, tom lane

In response to

pgsql-novice by date

Next:From: Todd KoverDate: 2004-09-18 00:31:13
Subject: Re: arrays and functions in plpgsql
Previous:From: Todd KoverDate: 2004-09-17 23:56:29
Subject: Re: arrays and functions in plpgsql

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