I combine these column as primary key.
room_no, type
When I insert new data for example, 0001 01.
And then I insert 0001 02.
It can not be done. It said duplicate primary key. Why it duplicate although I define 2 columns as a primary key.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This is same as compsite primay key working.
You can read this article:- http://www.techrepublic.com/article/the-great-primary-key-debate/1045050