By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,575 Members | 1,948 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,575 IT Pros & Developers. It's quick & easy.

Ascending and count help

P: n/a
Below is the statement i am working with and i am trying to figure out
how to have the count in ascending order...is this possible? Right now
it groups by FP in alphabetical order but i dont want that i want the
whatever the FP1 count is to be ascending but i am not sure how to go
about doing this...so any help or ideas?

SELECT FP1 AS FP, COUNT(FP1) AS Expr1
FROM dbo.FP1
WHERE (FP1 IS NOT NULL) AND (LTRIM(RTRIM(FP1)) <> '')
GROUP BY FP1

Jul 23 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
ORDER BY is the way (the only way) to sort the result of a query.

Just add

ORDER BY expr1

--
David Portas
SQL Server MVP
--
Jul 23 '05 #2

P: n/a
Thank you...that worked :)

David Portas wrote:
ORDER BY is the way (the only way) to sort the result of a query.

Just add

ORDER BY expr1

--
David Portas
SQL Server MVP
--


Jul 23 '05 #3

P: n/a
Thank you...that worked :)

David Portas wrote:
ORDER BY is the way (the only way) to sort the result of a query.

Just add

ORDER BY expr1

--
David Portas
SQL Server MVP
--


Jul 23 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.