Hello, I'm running 3 similar queries towards 3 different tables on the same database.Select MIN(Started) as Started, MAX(Ended) as Ended from tbl_DBWhere btj_id = 9And started > '01/06/09'GROUP BY StartedORDER BY Started ascSelect MIN(Started) as Started, MAX(Ended) as Ended from tbl_DBWhere btj_id = 15And started > '01/06/09'GROUP BY StartedORDER BY Started ascSelect MIN(Started) as Started, MAX(Ended) as Ended from tbl_DBWhere btj_id = 39And started > '01/06/09'GROUP BY StartedORDER BY Started asc
The result is very simiar in format: Started time on the left and ended time on the right.Started Ended2009-06-01 17:06:58.000 2009-06-01 17:14:48.0002009-06-01 17:07:03.000 2009-06-01 17:14:46.0002009-06-01 17:07:11.000 2009-06-01 17:14:46.000...2009-06-01 17:01:12.000 2009-06-01 17:03:19.0002009-06-02 17:01:12.000 2009-06-02 17:03:00.0002009-06-03 17:00:45.000 2009-06-03 17:02:30.000...2009-06-01 17:52:43.000 2009-06-01 17:52:46.0002009-06-02 18:06:16.000 2009-06-02 18:06:18.0002009-06-03 18:53:04.000 2009-06-03 18:53:06.000...
How can I have a single query returning a single table with the earliest starting time and the latest ending time each day between the 3 tables?[code]Any help would be much appreciated!Thanks