db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Conor66 <conor21e...@yahoo.ie>
Subject Re: New developer, need a little help with a subquery
Date Tue, 26 Jul 2011 20:14:09 GMT

That worked right off the bat :) Thank you so much, I really appreciate it


Thomas Hill-3 wrote:
> 
> if I understand correctly you need a 'group by' in your query; 
> so like
> SELECT  day("dtmDateCompleted") as "Day", 
> 	"A"."strName" AS "Category", 
>         COUNT(*)
>   FROM "tblAssetCategory" "AC" 
>        INNER JOIN "tblAsset" "A" ON "AC"."id" = "A"."intCategoryID"
>        INNER JOIN "tblWorkOrder" "W" ON "W"."intAssetID" = "A"."id"
>  WHERE "dtmDateCompleted" IS NOT NULL 
> GROUP BY day("dtmDateCompleted"), "A"."strName"
> 
> 
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/New-developer%2C-need-a-little-help-with-a-subquery-tp32142730p32143148.html
Sent from the Apache Derby Users mailing list archive at Nabble.com.


Mime
View raw message