Troubleshooting
Creating Tables
Q1: | Why won't the database let me create a primary key using a column that allows null values? |
Some databases require the primary-key column to have a non-null value at all times. Although some databases might permit null values, the fact that the column is a primary key means that you can have at most one null value for that column in the table, because the primary key must be unique. | |
Q2: | Why does the database complain that my table already exists? |
To create a new version of a table, you should first use the DROP TABLE command to delete the old version. Keep in mind, however, that DROP TABLE deletes all the data in the old table. | |
Q3: | Why won't the database let me create a table? |
Some databases have security settings that ... |
Get Special Edition Using Java™ 2 Enterprise Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.