This has worked fine for many years

mcols="XD"+ALLTRIM(STR(trcask13))
SELECT date,pcode,cycle,SUM(gross) as gross, SUM(tax) as tax,
SUM(ROUND((gross+nontgross)*(&mcols/100),2)) as super, &mcols as mpercent
FROM palldets ;
WHERE BETWEEN(cycle,trcask2,trcask3) ORDER BY pcode group BY pcode INTO
TABLE temp

Why does this give me grief
mcols="XD"+ALLTRIM(STR(trcask13))
mmvu ="XD"+ALLTRIM(STR(trcask14))
SELECT date,pcode,cycle,SUM(gross) as gross, SUM(tax) as tax,;
SUM(ROUND((gross+nontgross)*(&mcols/100),2)) as super, &mcols as mpercent ;
SUM(ROUND((gross+nontgross)*(&mmvu/100),2))  as volsup,&mmvu  as volp FROM
palldets ;
WHERE BETWEEN(cycle,trcask2,trcask3) ORDER BY pcode group BY pcode INTO
TABLE temp

in this instance, mcols is XD11 and mmvu is XD39
Both XD11 and XD39 are fields in a table.

As you can see, I'm simply adding 2 more columns to the temp table

-- 
Kind regards,
Sytze de Boer


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

_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/CAG1nNy_RZD1T+j86i2Q5N1YswXs=_tbjhe3fkjtcycqkpga...@mail.gmail.com
** 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