Jump to content

Find Max_Date and Min_Date


raviprakashg

Recommended Posts

this My Query"Select StartDt,EndDt from Table1"Now i will get an Recordset with collection of StartDate and EndDate, What i want is form the recordset i want to get the MaxDate and MinDate from one of these field"i use ASP, MsAccess"i think u Understand my Problem, Help me pleaseUr Dear Ravi

Link to comment
Share on other sites

this My Query"Select StartDt,EndDt from Table1"Now i will get an Recordset with collection of StartDate and EndDate, What i want  is form the recordset i want to get the MaxDate and MinDate from one of these field"i use ASP, MsAccess"i think u Understand my Problem, Help me pleaseUr Dear Ravi

You should be able to use the max/min functions. You would do it something like this:
SELECT MAX(StartDt), MIN(EndDt)FROM Table1

Link to comment
Share on other sites

The best, most efficient, and easiest, way to do it is with the sql query...the one already provided should work. If you do it as the scripting level it will be more owrk for you and will take more processing power.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...