0

I have this query

SELECT TOP 1000 [lid]
      ,[userid]
      ,[datetime]
      ,[batch_id]
      ,[actionid]
      ,[pages]
      ,[group]
      ,[sitecode]
  FROM [mydb].[dbo].[tbl_recon_scan]
  GROUP BY CAST([datetime] AS DATE)

it seems not working with group by. I have looked at this and this guides, I could not find solution.

Anyone can tell me my problem with the query?

Community
  • 1
  • 1
Elyor
  • 5,396
  • 8
  • 48
  • 76

1 Answers1

0

You don't use any aggregate functions in query. So it shows every individual record.

Visit these link:

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
Manojkumar
  • 91
  • 11