goodk
asked on
select (count(job) + job) from AceData group by job ??
select (count(job) + job) from AceData group by job
using ms sql server
the above not working
want to show,
25 myJob
30 otherjob
01 badjob
using ms sql server
the above not working
want to show,
25 myJob
30 otherjob
01 badjob
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
I tried this, should this be ok? The results looks fine
Select (type +' ('+ ltrim(str(count(type))) +')' ) as xtest from AceData group by type
Select (type +' ('+ ltrim(str(count(type))) +')' ) as xtest from AceData group by type
ASKER
thanks
Yes that will work but why use to functions when you can get away with one
In programming trick is to make things simple not complicated
In programming trick is to make things simple not complicated
Select (type +' ('+ convert(varchar,count(type)) +')' )
ASKER
thanks
ASKER
resolved used str() to convert