Prepare Interview

Mock Exams

Make Homepage

Bookmark this page

Subscribe Email Address

Question: Explain the difference between a primary key and a unique key in MariaDB.
Answer: Both primary keys and unique keys in MariaDB enforce uniqueness, but a table can have only one primary key, while it can have multiple unique keys. Additionally, the primary key column(s) cannot contain NULL values, while unique key columns can have NULLs.
Is it helpful? Yes No

Most helpful rated by users:

©2025 WithoutBook