UPDATE question_choices SET total_rows = count(*) from care_lesson;
returns the following error (which is well-documented):
ERROR: cannot use aggregate function in UPDATE
LINE 1: UPDATE question_choices SET total_rows = count(*) from care_...
I wondered how I can put a row count from one table into another? I
can't figure it out.
Thanks very much,
pgsql-novice by date
|Next:||From: Mariateresa L||Date: 2010-06-01 20:33:51|
|Subject: Re: sql files in psql ?|
|Previous:||From: Jeanne Louize Emygdio||Date: 2010-06-01 12:16:59|
|Subject: Invitation to connect on LinkedIn|