I want to pull all the rows from a database for a month and if there are any rows in the beginning or in the end that are missing then I want to create fake rows, so every day there is 开发者_高级运维a schedule that one has to follow. How can I detect missing rows or how can I solve this issue?
From how to fill up the missing dates ??
fill a calendar table use that as your driving table (i.e. first one in your select) and do a LEFT JOIN on it.
Create and fill a calendar table
精彩评论