Query sorting

G

Guest

I have a query that outputs the following columns in left to right order: Paitent number, sex, postcode, admission date, discharge date, admission method code, discharge code and daignosis. How can i sort the data retrieved by the query by disharge date and then by admission date (remebering that the admission date is the cloumn left of the discharge date)?
 
R

RobFMS

In the SQL View, type:

SELECT ...
FROM ...
ORDER BY [Discharge Date], [Admission Date]

When you look at the query in Design view, you will see how it is designed.

HTH

--
Rob

FMS Professional Solutions Group
http://www.fmsinc.com/consulting

Software Tools for .NET, SQL Server, Visual Basic & Access
http://www.fmsinc.com

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Nickios said:
I have a query that outputs the following columns in left to right order:
Paitent number, sex, postcode, admission date, discharge date, admission
method code, discharge code and daignosis. How can i sort the data retrieved
by the query by disharge date and then by admission date (remebering that
the admission date is the cloumn left of the discharge date)?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top