schema-migration

How to move a model between two Django apps (Django 1.7)

给你一囗甜甜゛ 提交于 2020-01-08 18:21:05
问题 So about a year ago I started a project and like all new developers I didn't really focus too much on the structure, however now I am further along with Django it has started to appear that my project layout mainly my models are horrible in structure. I have models mainly held in a single app and really most of these models should be in their own individual apps, I did try and resolve this and move them with south however I found it tricky and really difficult due to foreign keys ect. However

How to move a model between two Django apps (Django 1.7)

孤街醉人 提交于 2020-01-08 18:19:50
问题 So about a year ago I started a project and like all new developers I didn't really focus too much on the structure, however now I am further along with Django it has started to appear that my project layout mainly my models are horrible in structure. I have models mainly held in a single app and really most of these models should be in their own individual apps, I did try and resolve this and move them with south however I found it tricky and really difficult due to foreign keys ect. However

How to move a model between two Django apps (Django 1.7)

孤街浪徒 提交于 2020-01-08 18:19:49
问题 So about a year ago I started a project and like all new developers I didn't really focus too much on the structure, however now I am further along with Django it has started to appear that my project layout mainly my models are horrible in structure. I have models mainly held in a single app and really most of these models should be in their own individual apps, I did try and resolve this and move them with south however I found it tricky and really difficult due to foreign keys ect. However

How to move a model between two Django apps (Django 1.7)

你离开我真会死。 提交于 2020-01-08 18:19:05
问题 So about a year ago I started a project and like all new developers I didn't really focus too much on the structure, however now I am further along with Django it has started to appear that my project layout mainly my models are horrible in structure. I have models mainly held in a single app and really most of these models should be in their own individual apps, I did try and resolve this and move them with south however I found it tricky and really difficult due to foreign keys ect. However

How the schema migration tools work?

旧街凉风 提交于 2019-12-23 18:05:25
问题 I have db based application and I delete the schema & db content every time whenever there is any changes in the schema. Now it is in development mode. Soon we release the application in production. But we suspect there could be many changes after we release the application in production use. The software shall be installed on many locations across the globe. (Not a web based app) How the schema migration tool work in this case? or How can we use them in typical database based applications

What is the recommended way to temporarily disable my Google App Engine app so that I can perform schema migration?

半城伤御伤魂 提交于 2019-12-22 08:34:59
问题 I'd like to disable user access to my app so that I can perform a schema migration. I've looked into a few possibilities and found possible shortcomings: Disable datastore writes - I'd rather just bring my whole application down so that people do not see any errors, etc. Also, I assume disabling writes will prevent me from performing the migration. Disable the application - It's not clear to me that this would disable it only for my users, leaving me unable to perform the migration. I am also

Support for schema migrations with JPA?

99封情书 提交于 2019-12-21 03:15:06
问题 I've been briefly looking at JPA recently, and I was wondering what the deal is with database schema migrations and staying lined up with the classes you've created. Is there support in JPA for this stuff? Utilities? Best Practises? Cheers! 回答1: I won't rely on JPA providers to update the database schema. Check Liquibase for one of the good approaches. 回答2: The short answer is no . If you change your beans, then you will have to migrate the existing schema by hand. So for Rails style database

Does Django natively support migrations

☆樱花仙子☆ 提交于 2019-12-11 02:27:48
问题 I've heard that all the new web frameworks like ROR, Django etc. follow the general principle of Agile and TDD. One part of following Agile and TDD is to make up your own design as you go from one iteration to other. This means that models and their schema will evolve with different versions of the app. I know that ROR supports schema migrations natively, However I'm not sure about django. My major concern is that how can I decide upfront all the schema related issues. Isn't it going back to

Django: flush command doesnt completely clear database, reset fails

雨燕双飞 提交于 2019-12-05 20:39:41
问题 I rewrote a lot of my models, and since I am just running a test server, I do ./manage.py reset myapp to reset the db tables and everything has been working fine. But I tried to do it this time, and I get an error, "The full error: contraint owner_id_refs_id_9036cedd" of relation "myapp_tagger" does not exist" So I figured I would just nuke the whole site and start fresh. So i did ./manage.py flush then did a syncdb this did not raise an error and deleted all my data, however it did not

Django: flush command doesnt completely clear database, reset fails

﹥>﹥吖頭↗ 提交于 2019-12-04 03:51:24
I rewrote a lot of my models, and since I am just running a test server, I do ./manage.py reset myapp to reset the db tables and everything has been working fine. But I tried to do it this time, and I get an error, "The full error: contraint owner_id_refs_id_9036cedd" of relation "myapp_tagger" does not exist" So I figured I would just nuke the whole site and start fresh. So i did ./manage.py flush then did a syncdb this did not raise an error and deleted all my data, however it did not update the database since when I try to access any of my_app's objects, i get a column not found error. I