Is it possible to create a table with only one column that holds every month since a given date? For instance with the given date 2016-01-01 I would like the following table:
Asked
Active
Viewed 100 times
0
-
Yes, its possible but why you need it.... if you explain the scenario may be people can suggest more... – Naincy Feb 28 '17 at 09:12
-
Do you mean you want a query that auto-generates those dates? – jarlh Feb 28 '17 at 09:12
-
Yes I want a query that autogenerate those dates. I want to sum the amount of some dynamic tables up to all of those dates. So for instance it could be a given customers consumption up to those dates – Nicolai Iversen Feb 28 '17 at 09:16
-
I am running MySQL workbench 6.3 and it does not seem that it supports creating procedures. There doesn't exist a more down to earth and less efficient method for doing this such that Workbench are capable of running it? – Nicolai Iversen Feb 28 '17 at 09:53
-
1Workbench is a visual tool for using the database, not the database. It might not give you a pretty interface option to create a procedure, but it can't not support it. Also, existance of questions like http://stackoverflow.com/questions/10084458/how-to-create-and-execute-procedures-in-mysql-workbench shows that it should work. – Deltharis Feb 28 '17 at 09:59
-
Okay I see that the problem is that my access is denied to the database when running the command. Guess this is a necessary condition to solve the asked question. – Nicolai Iversen Feb 28 '17 at 10:24