Normally I am creating a view using the ‘group by’ clause.

Then you are able to update corresponding column in clienttab, where the view 
is table t2.

 

Tony

 

 

From: [email protected] [mailto:[email protected]] On Behalf Of Patti Jakusz
Sent: maandag 5 oktober 2015 16:33
To: [email protected]
Subject: [RBASE-L] - update command help

 

I have a table of client records and a table of activity records.  
Occasionally, I want to count the number of certain types of activity records 
for a client and plug that number into the client table.  It should be a simple 
command, but I can't get it to work.  

 

Here are some of my attempts:

 

update CLIENTTAB set MyColumn=(count(*)) from ACTIVITY where CASENUM=CASENUM

 

update CLIENTTAB set MyColumn=(count(CASENUM)) from ACTIVITY where 
CASENUM=CASENUM

 

update CLIENTTAB set MyColumn=(count(CASENUM)) from CLIENTTAB t1, ACTIVITY t2 
where

         t1.CASENUM=t2.CASENUM

 

update CLIENTTAB set MyColumn=(select(count(CASENUM)) from ACTIVITY where 
CASENUM=CASENUM)

 

 

 

I know there has to be a simple command and I'm just not getting it.

 

Can someone help?

 

Thanks,

Patti

Reply via email to