Can we use more than one null value for unique key?
Answer Posted / pratibha
u can insert multiple null values without ant error:
SQL> create table sab(name varchar2(10) unique);
Table created.
SQL> insert into sab values('&sab');
Enter value for sab:
old 1: insert into sab values('&sab')
new 1: insert into sab values('')
1 row created.
SQL> /
Enter value for sab:
old 1: insert into sab values('&sab')
new 1: insert into sab values('')
1 row created.
SQL> /
Enter value for sab:
old 1: insert into sab values('&sab')
new 1: insert into sab values('')
1 row created.
SQL> /
Enter value for sab:
old 1: insert into sab values('&sab')
new 1: insert into sab values('')
1 row created.
SQL> /
Enter value for sab:
old 1: insert into sab values('&sab')
new 1: insert into sab values('')
1 row created.
SQL> SQL> select count(*) from sab;
COUNT(*)
----------
5
Is This Answer Correct ? | 10 Yes | 0 No |
Post New Answer View All Answers
What is the most restrictive isolation level? : Transact sql
What is partition in sql query?
Write a query to display the current date in sql?
Does truncate table reset auto increment?
What is dialect in sql?
What are analytical functions in sql?
What are the uses of sysdate and user keywords?
What is null in pl/sql?
Can we edit a view in sql?
what is the syntax used for partition in tsql? : Transact sql
What is the maximum number of triggers, you can apply on a single table?
What is oracle pl sql developer?
What is the difference between mdf and ndf files?
What is the order of sql select?
How can we optimize a sql query?