define primary key & secondary key?

Answers were Sorted based on User's Feedback



define primary key & secondary key? ..

Answer / manoj

primary key is a key which always accept unique value.

secondary key is a key which when you are making primary key
for more than one column as primary key for retrieving of
reords.
eg.
create table tnam
(ano number,
bno number,
bname char(12),
primary key(ano,bno))

In this bno is secondary key.

Is This Answer Correct ?    31 Yes 18 No

define primary key & secondary key? ..

Answer / renu kakkar

PRIMARY REPRESENTS THE ROW/TUPPLE UNIQUELY WHEREAS
SECONDARY KEY REPRESENTS THE SET OF TUPPLES
EMPLOY_ID IS A PRIMARY KEY AND EMPLOY_DEPTT. IS A SECONDARY
KEY.

Is This Answer Correct ?    3 Yes 9 No

Post New Answer

More SQL PLSQL Interview Questions

what are the methods using performance tunning in sql and pl/sql

2 Answers  


Dear All, Question for this Week Find out possible error(s) (either at compile time or at runtime) in the following PL/SQL block. State the reason(s) and correct the errors. Declare Cursor C1 is select ename, sal, comm from emp; Begin For i in C1 Loop If i.comm between 299 and 999 then Dbms_output.put_line(i.Ename || ‘ ** Good Commission’); Elsif i.comm > 999 then Dbms_output.put_line(i.Empno || ‘ ** Very Good Commission’); close C1; Else Dbms_output.put_line(i.Ename || ‘ ** ’ ||nvl(i.comm,‘O’)); End if; End Loop; End;

7 Answers   Accenture,


What is normalization? How many normalization forms are there?

0 Answers  


What is a constraint?

0 Answers  


What will be the output of the following String S = 1+2+"abc" S = ? String S1 = 1+2+"abc"+5+6 S1 = ?

1 Answers   ABC,






What is a parameter query?

0 Answers  


What are code pages ?

1 Answers   BirlaSoft,


What's the procedure?

0 Answers  


How does sql store data?

0 Answers  


ename empno deptno amar 1 10 akbar 2 20 anthonny 3 30 jonathan 4 40 write a procedure to dispaly the column values ina row separated by a deleimiter eg - input - select ename from emp '|' output - amar|akbar|anthony|jonathan input - select empno from emp '@' o/p - 1@2@3@4 input - select deptno from emp '/' o/p - 10/20/30/40 Pls answer this questn.

2 Answers  


What is update query?

0 Answers  


Can we use ddl statements in stored procedure sql server?

0 Answers  


Categories