Solved

Compile Maria database very 30 days interval

Posted on 2015-01-29
1
138 Views
Last Modified: 2015-02-13
Hi , Good day,

I am getting raw data into my database (table) every second and filling up my database - no issue on that part. I want to compile my data every 30 days interval automatically example date from 15/jan ~ 14/feb and so on. Is that possible in Maria db
0
Comment
Question by:TITO2009
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 42

Accepted Solution

by:
pcelba earned 500 total points
ID: 40578380
Yes, this is possible. You may use ADDDATE or DATE_ADD function to calculate the date + 30 days.

More info: https://mariadb.com/kb/en/mariadb/date-and-time-functions/

To execute the compilation every 30 days just CREATE EVENT: https://mariadb.com/kb/en/mariadb/events/

More info: https://mariadb.com/kb/en/mariadb/create-event/

Your compilation will be more complex than one simple statement so I would recommend to create and call Stored Procedure.

More info: https://mariadb.com/kb/en/mariadb/stored-procedures/
0

Featured Post

Get Database Help Now w/ Support & Database Audit

Keeping your database environment tuned, optimized and high-performance is key to achieving business goals. If your database goes down, so does your business. Percona experts have a long history of helping enterprises ensure their databases are running smoothly.

Question has a verified solution.

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

Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
As technology users and professionals, we’re always learning. Our universal interest in advancing our knowledge of the trade is unmatched by most industries. It’s a curiosity that makes sense, given the climate of change. Within that, there lies a…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

734 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