-
Notifications
You must be signed in to change notification settings - Fork 55
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
Why not use 'create table if not exist' ? #43
Comments
create table if not exist
?
Thanks for your response! Sorry for ignorance of #1 I could reproduce Also, in my django program there is no insert action for the partition table, so I choose to Thanks again! |
Yes, that makes total sense, you can add a PR for that if you have time, I will gladly accept that change. I can't really say right now from the top of my head why we use |
Regarding |
I've tried to add But there are some limitations:
|
Cool, great job. Let's wait for the answer regarding peewee a bit. |
The before-insert trigger in Postgres is something like:
And it will check whether table's existense by
SELETC 1
, then create table if select failed.I tried to replace withCREATE TABLE IF NOT EXIST
In my case, it will speed up insert action about 25% (I really care about the decrease of insert action's speed). But I doubt that it is too special, so I open this issue to discuss about it. Thanks!
The text was updated successfully, but these errors were encountered: