Say I have a model that represents a product from my company. Each product a product number (ex. 5928523), as well as a boolean representing whether or not it is an experimental product.
class Product(models.Model):
product_number = models.IntegerField()
experimental = models.BooleanField(default=False)
Say I want to merge these two fields into one character field, a product ID. So an experimental product with product number 3892 would turn into "X3892" and a non-experimental product with product number 937 would simply turn into "937".
class Product(models.Model):
product_id = models.CharField()
How would I write a database migration in Django to achieve this?