Can someone help me with this please
I have a table with lots of entries, and trantype either D or P
All values of ttlvalue are positive

I perform this
SELECT IIF(trantype='D',SUM(ttlvalue),SUM(ttlvalue)*-1) FROM MYTABLE INTO
CURSOR P3

It gives me the grand total of all transactions, regardless.
What I need is D(eposits)  less P(ayments)


-- 
Regards
Sytze de Boer
Kiss Systems
Ph: 64-7-8391670, Mob:021 937611,
Skype: kissman2
www.kiss.co.nz


--- StripMime Report -- processed MIME parts ---
multipart/alternative
  text/plain (text body -- kept)
  text/html
---

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to