Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up

Which Django operation is safest to run on a very large table?

  1. A Adding a nullable column with no default
  2. B Adding a NOT NULL column with a default on an old database version
  3. C Creating an index without CONCURRENTLY
  4. D Altering a column type
Answer

Adding a nullable column with no default

On PostgreSQL a nullable column with no default is a metadata-only change. The other operations can lock the table for an extended period.

All Django MCQs

Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up as