Solved

MYQL Month ,Year list

Posted on 2012-03-27
4
556 Views
Last Modified: 2012-03-29
I want the output like the below rows in mysql.The logic is from current month year to next 20 month year.

March 2012
April 2012
May 2012
June 2012
.....
....
December 2013
0
Comment
Question by:dynamicweb09
4 Comments
 
LVL 9

Expert Comment

by:OCDan
ID: 37775259
Whats your starting data?
0
 
LVL 24

Assisted Solution

by:johanntagle
johanntagle earned 250 total points
ID: 37775271
See http://stackoverflow.com/questions/9511409/creating-a-list-of-month-names-between-two-dates-in-mysql just change the start and end dates and also change MonthName(aDate) to date_format(aDate, '%M %Y')
0
 
LVL 1

Author Comment

by:dynamicweb09
ID: 37775281
my starting data is from current month and year. and we need next 20 month and year.everything is dynamic.
0
 
LVL 20

Accepted Solution

by:
BuggyCoder earned 250 total points
ID: 37775407
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Clone table from one server.database to another server.database 24 48
MySQL recovery 7 27
What is this datetime? 1 25
MySQL-Design Help 12 38
As a database administrator, you may need to audit your table(s) to determine whether the data types are optimal for your real-world data needs.  This Article is intended to be a resource for such a task. Preface The other day, I was involved …
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question