raviprakashg Posted January 11, 2006 Share Posted January 11, 2006 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 More sharing options...
Kcarson Posted January 11, 2006 Share Posted January 11, 2006 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<{POST_SNAPBACK}> 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 More sharing options...
pulpfiction Posted January 11, 2006 Share Posted January 11, 2006 Hi Ravi,Well if you want to do it in ASP, it is definitly tedious, one option is to sort the dates and take the first and last value.HTH Link to comment Share on other sites More sharing options...
aspnetguy Posted January 11, 2006 Share Posted January 11, 2006 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 More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now