searchsanjaysharma
asked on
How to write the group by query to find highest.
I have a table mstenquiries
It contains city,course,feeddate
i want to find the feeddate having highest no. of enquiries.
select top 1 Convert(varchar,feeddate,1 06),count( *) from cuaf.dbo.mstcuaf where sname not like 'Test%' and course<>'' group by Convert(varchar,feeddate,1 06) order by 2 desc
This result will give date and highest count
Now i want the course on this day which was having the highest enquiries.
How to find that/
It contains city,course,feeddate
i want to find the feeddate having highest no. of enquiries.
select top 1 Convert(varchar,feeddate,1
This result will give date and highest count
Now i want the course on this day which was having the highest enquiries.
How to find that/
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER