jon15n Posted February 9, 2009 Share Posted February 9, 2009 I'm sure there is an easy solution, but here goes: I'm querying a table and grouping by dates. Here is an example: DATE | value 2009-02-05 | 33 2009-02-07 | 40 2009-02-08 | 24 I want to be able to query it so that 2009-02-06 will show up even though it isn't in the table. Is this possible? Your help is greatly appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/144533-solved-probably-easy-date-query-just-cant-wrap-my-head-around-it/ Share on other sites More sharing options...
jon15n Posted February 9, 2009 Author Share Posted February 9, 2009 I decided to join a table with days.. is this the only way? or is there a function/process I don't know about. Quote Link to comment https://forums.phpfreaks.com/topic/144533-solved-probably-easy-date-query-just-cant-wrap-my-head-around-it/#findComment-758531 Share on other sites More sharing options...
corbin Posted February 9, 2009 Share Posted February 9, 2009 Grouping by data that doesn't exist wouldn't make much sense. Why not just handle it in what ever you're using to execute the query (PHP for example)? Quote Link to comment https://forums.phpfreaks.com/topic/144533-solved-probably-easy-date-query-just-cant-wrap-my-head-around-it/#findComment-758548 Share on other sites More sharing options...
fenway Posted February 15, 2009 Share Posted February 15, 2009 I decided to join a table with days.. is this the only way? or is there a function/process I don't know about. I really hope that table is generated dynamically.... Quote Link to comment https://forums.phpfreaks.com/topic/144533-solved-probably-easy-date-query-just-cant-wrap-my-head-around-it/#findComment-762677 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.