buddyrich2
Technical User
This one may be a little hard to explain but please bear with me.
For each account, I have a table that contains the fields (for example) tot1, tot2, tot3, etc. I also have a field called grand_tot, which is the sum of all these other fields. To get grand_tot, I put "tot1+tot2tot3...." in my program. So far so good.
Problem is: the number of these "tot fields" vary from account to account. If I try to satisfy the largest account, the program of course complains that the field is not there.
Is there anyway I can write a 'variable routine' in the program to take the number of these fields (I could put this number in a master table) and total these columns regardless of how many their are?
Thanks in advance for your help!
For each account, I have a table that contains the fields (for example) tot1, tot2, tot3, etc. I also have a field called grand_tot, which is the sum of all these other fields. To get grand_tot, I put "tot1+tot2tot3...." in my program. So far so good.
Problem is: the number of these "tot fields" vary from account to account. If I try to satisfy the largest account, the program of course complains that the field is not there.
Is there anyway I can write a 'variable routine' in the program to take the number of these fields (I could put this number in a master table) and total these columns regardless of how many their are?
Thanks in advance for your help!