cancel
Showing results for 
Search instead for 
Did you mean: 

SQL Command has data but not displaying

Former Member
0 Kudos
59

The following I put in Command and run ok. But the Command creates 1 field here called 0001 and it only displays this '0001' in the report.

But, if you do a browse data, you get the actual count from first part and you get the sum from second.  but why cr not displayed that?

SELECT count(*) FROM  ASTCCDTA.OEORH48        

WHERE OHORDT IN('RTR','INT','SAM')  

AND OHREQD <replace(char(current date, iso), '-', '')

AND OHHLDC <> ' '

union

SELECT SUM(OdQty#) FROM  ASTCCDTA.OEORH48,ASTDTA.OEORD1        

WHERE OHCOM# = ODCOM# AND OHORD# = ODORD#

AND ODPRT# = OdAls# AND substr(odprt#,1,3) <> 'FRT'

AND OHORDT IN('RTR','INT','SAM') 

AND OHREQD <replace(char(current date, iso), '-', '')

AND OHHLDC <> ' '

View Entire Topic
abhilash_kumar
Active Contributor
0 Kudos

Hi Paul,

Always Alias summaries:

SELECT count(*) Count_Something FROM  ASTCCDTA.OEORH48


Drag and drop the above field on the Details Section and see how many records you see.


-Abhilash