i am working with big data and i can have an extra column like id. i cant put the primary key to any other single column, because of duplicate. and even more i cant have primary key on two column or more because my data is not unique. so the only way to get rid of the id column with a primary key left for me is to stop django making it! and i don't know how... i tried to edit the operation part of the migration file before doing the migrate command but it didn't work. even if i delete the id column in the migration file it still make it /:(.
how to make a django model with no id column and primary key?
38 Views Asked by nilian At
0
There are 0 best solutions below
Related Questions in DJANGO
- Django Admin Panel and Sub URLs Returning 404 Error on Deployment
- How to return HTTP Get request response from models class in Django project
- Issue with Quantity Increment in Django E-commerce Cart
- Can't install Pipenv on Windows
- use dict from python in django html template and also in js
- 'pyodbc.Cursor' object has no attribute 'callproc', mssql with django
- Django socketio process
- Root path analogue in uWSGI as in Uvicorn
- Django - ModuleNotFoundError: No module named 'backend'
- Does Python being a loosely typed programming language make it less secure?
- sorl-thumbnail adds a background color when padding is used
- Can't connect to local postgresql server from my docker container
- Why ProductHunt api dont work with Python?
- why i have to put extra space in before write option selected because it show error if i don't ' option:selected'
- Django Arrayfield migration to cloud sql (Postgresql) not creating the column
Related Questions in POSTGRESQL
- Only the first SQL script gets executed inside Docker Postgres container
- Compare fields in two tables
- Hibernate ClobJdbcType bindings: what are the diferences?
- Postgres && statement Error in Mybatis Mapper?
- Can this query be optimized? (Choosing a random row to insert, that excludes previously inserted Rows)
- Connection terminated unexpectedly while performing multi row insert using pg-promise
- Processing multiple forms in nodejs and postgresql
- How to copy data from SQLite to postgreSQL?
- PGAdmin4 configured behind a reverse proxy but unable to connect to Postgresql server
- Updates to pgsodium encrypted values don't use specified key_id
- Connecting to Postgres running in a Docker container using psql
- Can't connect to local postgresql server from my docker container
- Django Arrayfield migration to cloud sql (Postgresql) not creating the column
- Get list of matching keywords for each post
- docker-compose can't reset postgresql database
Related Questions in ORM
- SQL schema for a fill-in-the-blank exercise
- ERROR: column "country" is of type text[] but expression is of type record (SQLSTATE 42804)
- JPA Hibernate OneToOne Mapping
- query in objects with django orm with a containing sentence
- peewee: SQLite - peewee Create() is forcing integer in PrimaryKeyField if leading character is numeric (even if there is a non-numeric in the middle)
- PHP ORM DOCTRINE
- Error appending to array oOnConflictUpdaste using Drizzle ORM (Postgresql)
- Sequelize foreign key vs SQL how to implement it
- How do i work with a potentially nullable field in prisma ORM and MongoDB that references the id of another model?
- record doesn't exist error when creating a new record
- Several relationships in one model in Laravel
- SQLALCHEMY ORM - error when using variables both for column, value in WHERE
- How to exclude instances with empty querysets in prefetch_related?
- Optimize SqlAlchemy ORM DB models
- What are the best practices regarding SSR, Django and temprarly changed data?
Related Questions in PRIMARY-KEY
- Claves combinadas
- Postgresql Primary Key Index Maintenance
- "Number of referencing columns in foreign key differs from number of referenced columns" inline error
- Entity Framework Core 7 - configuring two keys
- Create a flexible key for merge in R
- Record versioning and approving changes TypeOrm postgres
- Primary key issue of a table imported from CSV, using MySQL Workbench (Linux Mint 21 Vanessa)
- Why Hibernate now uses TABLE strategy as default for MySQL?
- how to make a django model with no id column and primary key?
- CockroachDB: The best way to turn a UNIQUE CONSTRAINT into a PRIMARY KEY?
- Alter entries of Primary key in table to match number of rows from COUNT Postgresql
- How to update a part of primary key if it is a combination of three columns
- Is it wise to construct a custom string (combination of entity, year and alphanumeric) to have as a primary key for a postgres database in Django?
- Django filtering with Custom primary key
- TypeORM joins by multiple PrimaryColumns ignoring defined JoinColumn
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?