Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Archive feature #3

Open
ryan876smith opened this issue Mar 17, 2014 · 3 comments
Open

Archive feature #3

ryan876smith opened this issue Mar 17, 2014 · 3 comments

Comments

@ryan876smith
Copy link

Any solutions for a archive feature since my DB is filling up quickly

@cornernote
Copy link
Owner

If you are using MySQL then try pt-archiver.

If you are using SQLite then rename the database each month.

Let me know if you have any other ideas or suggestions and I can add all this into the docs.

@dadinugroho
Copy link

Hi cornernote,

It's me again. I am really impressed with this yii-ext and your support to make this ext better.

Somehow, I am interested in this issue. Especially when we want to separate the data and the log. The capability to use mysql or sqlite is great. But, I am not sure. Can we implement that? I mean my data is as usual sored in mysql, but this extension will be using sqllite. This would be better if we have the automatic sqlite file for every month.

Thank you very much.

@cornernote
Copy link
Owner

Hi @dadinugroho,

You can simply put a cron script to move the sqlite database, then set 'autoCreateTables' => true in the config, which will create a new database.

The problem will be looking at the old data. You can use ATTACH DATABASE and UNION to query multiple sqlite databases in a single query. It may be possible to setup a yii connection to automatically do this, but I haven't looked into it.

If you find any useful resources to do this please link them to this issue and I'll look into them.

@csa12 csa12 mentioned this issue Jun 2, 2014
@gb5256 gb5256 mentioned this issue Oct 31, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants