pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Questions for experts
3+ messages / 3 participants
[nested] [flat]

* Questions for experts
@ 2003-05-13 12:15 SEB Menard <smenard@avior.ca>
  2003-05-14 15:34 ` Re: Questions for experts Richard Huxton <dev@archonet.com>
  2003-05-14 16:02 ` Re: Questions for experts Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 2 replies; 3+ messages in thread

From: SEB Menard @ 2003-05-13 12:15 UTC (permalink / raw)
  To: pgsql-sql

I want to perform dynamic SQL update in PL/PGSQL... i don't know the
name of the columns that i want to update. i just want to update a
complete line... How i can get the names of the columns of a table in
PL/PGSQL for produce a dynamic  SQL update? 

In Oracle UPDATE ...SET ROW do the jobs any substitutes in POSTGRES?


Thanks a lot!!!!
   




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Questions for experts
  2003-05-13 12:15 Questions for experts SEB Menard <smenard@avior.ca>
@ 2003-05-14 15:34 ` Richard Huxton <dev@archonet.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Richard Huxton @ 2003-05-14 15:34 UTC (permalink / raw)
  To: SEB Menard <smenard@avior.ca>; pgsql-sql

On Tuesday 13 May 2003 1:15 pm, SEB Menard wrote:
> I want to perform dynamic SQL update in PL/PGSQL... i don't know the
> name of the columns that i want to update. i just want to update a
> complete line... How i can get the names of the columns of a table in
> PL/PGSQL for produce a dynamic  SQL update?
>
> In Oracle UPDATE ...SET ROW do the jobs any substitutes in POSTGRES?

Start psql with the -E flag, then \d etc will show you the queries they run to 
provide their output. There's also a system catalogue section in the manuals

-- 
  Richard Huxton



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Questions for experts
  2003-05-13 12:15 Questions for experts SEB Menard <smenard@avior.ca>
@ 2003-05-14 16:02 ` Tom Lane <tgl@sss.pgh.pa.us>
  1 sibling, 0 replies; 3+ messages in thread

From: Tom Lane @ 2003-05-14 16:02 UTC (permalink / raw)
  To: SEB Menard <smenard@avior.ca>; +Cc: pgsql-sql

SEB Menard <smenard@avior.ca> writes:
> I want to perform dynamic SQL update in PL/PGSQL... i don't know the
> name of the columns that i want to update. i just want to update a
> complete line... How i can get the names of the columns of a table in
> PL/PGSQL for produce a dynamic  SQL update? 

Use pltcl, not plpgsql.  This sort of thing is easy in pltcl, hard or
impossible in plpgsql.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2003-05-14 16:02 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-05-13 12:15 Questions for experts SEB Menard <smenard@avior.ca>
2003-05-14 15:34 ` Richard Huxton <dev@archonet.com>
2003-05-14 16:02 ` Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox