Questions tagged [schema-migration]

Schema migration refers to altering the data schema used in an application. This may merely involve changing the database, but frequently also involves code alterations.

Schema migration refers to altering the data schema used in an application. This may merely involve changing the database, but frequently also involves code alterations.

Because the data schema is often relatively stable, and code usually embeds assumptions about it, schema-migration must be handled carefully.

64 questions
3
votes
1 answer

Applied migration entry not presente on schema_migrations table

I got an app running in production on heroku, but there is a problem with the schema_migrations table. The last migration changes are present at the db/schema.rb file, but there is no entry for this migration in the schema_migrations table. So when…
3
votes
1 answer

schema evolution of complex types

What is the status of schema evolution for arrays of structs (complex types) in spark? I know that for either ORC or Parquet for regular simple types works rather fine (adding a new column) but I could not find any documentation so far for my…
Georg Heiler
  • 16,916
  • 36
  • 162
  • 292
3
votes
2 answers

PostgreSQL schema migration?

I've local PostgreSQL database with tables, constraints, relations etc. How can I migrate it to a production server?
Daulet Nurgali
  • 167
  • 1
  • 3
  • 8
3
votes
1 answer

Django ORM migration giving "ValueError: invalid literal for int()" on IntegerField

Step by step, here is how I got to where I am now... I attempted ran the command python manage.py migrate after changing my Order table in my database to include include flowertype = IntegerField() and was told that I couldn't move forward with the…
Erik Åsland
  • 9,542
  • 10
  • 30
  • 58
2
votes
1 answer

Best practice for running database schema migrations

Build servers are generally detached from the VPC running the instance. Be it Cloud Build on GCP, or utilising one of the many CI tools out there (CircleCI, Codeship etc), thus running DB schema updates is particularly challenging. So, it makes me…
2
votes
1 answer

How to implement schema migration for PostgreSQL database

I need to implement schema migration mechanism for PostgreSQL. Just to remove ambiguity: with schema-migration I mean that I need upgrade my database structures to the latest version regardless of their current state on particular server instance.…
Pavlo
  • 1,594
  • 2
  • 15
  • 30
2
votes
1 answer

Firestore full collection update for schema change

I am attempting to figure out a solid strategy for handling schema changes in Firestore. My thinking is that schema changes would often require reading and then writing to every document in a collection (or possibly documents in a different…
twiz
  • 9,041
  • 8
  • 52
  • 84
2
votes
1 answer

Migrate library implementation for cassandra with multiple host ip's

I am trying to use golang-migrate library for cassandra migrations. In the Docs, they have mentioned to use cassandra url like this cassandra://host:port/keyspace?param1=value¶m2=value2 We will be having more than one host for cassandra. Do…
Gokul Raj Kumar
  • 335
  • 2
  • 9
2
votes
1 answer

Setting Oracle's Column COMMENTS Attribute with NHibernate

One of my larger applications is using NHibernate over an Oracle data store. For testing/development, the application uses NHibernate's schema generation to create/re-create the database when needed. Prior to delivery, one of the things being asked…
nkirkes
  • 2,635
  • 2
  • 21
  • 36
2
votes
1 answer

How to use Flyway in a multi-schema MS SQL Server environment?

We have a multi-tenant SaaS application using the "multi-schema" strategy i.e. every customer has dedicated schema in the same database instance. We are using MS SQL Server as the database which switches between schema's through the "default schema"…
Sheraz Khan
  • 43
  • 2
  • 5
2
votes
3 answers

Django South - schema and data migration at the same time

Isn't it possible to do something like the following with South in a schemamigration? def forwards(self, orm): ## CREATION # Adding model 'Added' db.create_table(u'something_added', ( (u'id',…
lajarre
  • 4,910
  • 6
  • 42
  • 69
2
votes
3 answers

Does Django natively support migrations

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…
VaidAbhishek
  • 5,895
  • 7
  • 43
  • 59
2
votes
1 answer

UIManagedDocument documentState == 5, undefined state constant

While working with Core Data, I have found that my UIManagedDocument object has a documentState equal to 5. The UIDocument documentation only defines these constants: enum { UIDocumentStateNormal = 0, UIDocumentStateClosed =…
Jeff Lockhart
  • 5,379
  • 4
  • 36
  • 51
2
votes
3 answers

problems updating DB to heroku with south migrations

I have a Django proyect running in heroku for some time now, the thing is that, tree days ago, I've tryed to update my schema model but, every time I write heroku run python manage.py migrate quizzer heroku keeps telling me that everything's up to…
Sascuash
  • 3,661
  • 10
  • 46
  • 65
2
votes
1 answer

What is the use of models attribute in South SchemaMigration class?

In every generated migration files by South manage.py schemamigration, there usually will be a subclass of the south.v2.SchemaMigration. The class would contain forwards() and backwards() methods and also models attribute. How does South use the…
pram
  • 1,484
  • 14
  • 17