Skip to main content

What is Key in the Database


What is Key in the Database


What is Key in the Database

Key (Data Base Key)

1) Keys are used to establish and identify relationship between tables in database.
2) They also ensure that each record within a table can be uniquely identified by
combination of one or more fields within a table.
3) There are various keys which plays an important role in designing the database.
Primary Key:
1) The attribute values which are unique within the relation that can be used to
identify the entity/tuples of that table/relation, is called primary key.
2) For example: (1) attribute “Student_Id”, can be used as primary key, since every
student has unique “Student_Id” in a Student database. (2) attribute “Account_No’,
can be used as primary key, since every Customer has unique “Account_No” in a
Bank database.

Super Key or Combination Key:

I) Super Key is defined as a set of attributes, taken collectively, within a table 
uniquely identifies each record within a table.
2) Such keys are also known as combination key. 
combination Key


Candidate Key:

1) Candidate keys are defined as a set of fields from which primary key can be
selected.
2) It is an attribute or set of attributes that can act as a primary key for a table to
uniquely identify each record in that table. 


Secondary or Alternate Key:

1) The candidate key which are not selected for primary key is known as secondary
key or alternate key.
2) In the above table. Either Student_id or Roil_No is primary key and other will be
alternate key.
Non-key Attribute (Non-prime attribute):
1) All attributes other than candidate key attributes are called Non-key attribute.
2) The Non-key attribute is also known as non-prime attributes.
3) In the above table “Name”, “Address” and “course” are non-Key attributes.
Foreign Key:
1) Foreign key is generally a primary key from one table that appears as a field in
another table, where the first table has relationship with second.
2) Non-key of one table, which is a primary key of another table, is called Foreign key
3) Consider a table “Course” that has “course_Id” as primary key and consider another
table “student” that has “course_id” as one of its attribute, then “course_Id” would
be the “foreign Key” in “student” table.

What is Entity in Database


Popular posts from this blog

How to create the account on payza and make money from the world ?

How to create the account on payza and make money from the world ? What is a Payza account? Payza may be a terribly convenient and safe resolution for businesses and professionals to send and settle for cash from any location within the world. Accounts are accessible for those that need to use Payza for private use in addition as business accounts for larger and complicated needs. How am i able to withdraw cash from Payza to my bank account? To withdraw by bank wire or bank transfer, follow these steps: In your Payza account, click “Withdraw Funds” within the prime menu, then choose “Bank Wire” or “Bank Transfer”. Select your Payza currency balance and also the checking account to withdraw to. Enter your bank data, amount, and details, then click “Next”. How to Earn Money Online ? Can I receive cash through payza in Nigeria? Our members in African country will deposit cash into their Payza accounts by draft, cheque or bank wire. For reasons on the fa

औंढा नागनाथ ज्योतिर्लिंग मंदिर दर्शन | Aundha Nagnath Jyotirling Darshan

औंढा नागनाथ ज्योतिर्लिंग मंदिर दर्शन | Aundha Nagnath Jyotirling Darshan बारा ज्योतिर्लिंग हे भारतातील हिंदूंचे तीर्थक्षेत्र आहेत. त्यातील पाच महाराष्ट्रात आहेत. शतकानुशतके या ठिकाणी शिवांची पूजा केली जाते. औंढा नागनाथ हे त्यापैकी एक आहेत. अनुज्ञान नागनाथ हिंगोली जिल्ह्यात आहेत 12 ज्योतिर्लिंगांपैकी हा आठवा (आद्या) मानला जातो म्हणून हा तीर्थयात्रा केंद्र महान महत्व आहे. असे मानले जाते की, धर्माराज (पांडवपैकी सर्वात मोठे) याने हेस्तिनापूरला 14 वर्षांपासून निर्वासित केले होते. नागनाथ मंदिराला उत्तम कोरीव काम आहे. मंदिर हेमाडपंती वास्तुशिल्प आहे आणि सुमारे 60,000 चौरस फूट क्षेत्रावर स्थित आहे. शिवरात्री आणि विजयादशमी वर मोठ्या संख्येने यात्रेकरू या मंदिरात येतात. 12 ज्योतिर्लिंगांपैकी एक असलेले औंढा नागनाथ हे हिंगोली जिल्ह्यातील पवित्र तीर्थक्षेत्र आहे. यालाच  अष्टम ज्योतिर्लिंग श्री नागेश्वर ज्योतिर्लिंग   असे म्हणतात, या शहराचे सध्याचे नाव हे  औंढा  असून पूर्वीच्या काळी याचे नाव हे  दारुकावण  असे होते, हे ठिकाण  महाराष्ट्रात हिंगोली जिल्ह्यातील औंढा तालुक्यात  आहे, मंदिराचा अती प्राचीन

नरनाळा किल्ला अकोला | Narnala Fort Akola

 नरनाळा किल्ला अकोला | Narnala Fort Akola नरनाळा किल्ला हा गोंड राजाने बांधलेला अती प्राचीन किल्ला आहे. अकोट तालुक्याच्या उत्तरेला साधारण २४ कि.मी. वर सातपुड्याच्या उंच डोंगरावर हा किल्ला पसरलेला आहे. अकोल्यापासून याचे अंतर ६६ कि.मी. आहे. गडाच्या खाली शहानूर नावाचे गाव आहे. गडाच्या पायथ्यापासून मेळघाट व्याघ्रप्रकल्प सुरू होतो. पायथ्यापासून गडावर जाण्याकरिता आता गाडीवाट आहे. तरीही कित्येक दुर्गप्रेमी पायीच गड चढणे पसंत करतात. पायथ्याशी वन विभागाच्या चौकीवर जाता येता नोंद करावी लागते, गडावर मुक्कामास परवानगी नाही. गड जमिनीपासून ३१६१ फूट उंच आहे. गडाचा विस्तार हा ३८२ एकराचा असून गडाच्या कोटाची (तटबंदीची) लांबी २४ मैल आहे. एकूण दोन लहान व एक मोठा असा मोठा पसारा असणारा हा बहुधा महाराष्ट्रातील सर्वात विर्स्तीण गिरिदुर्ग असावा. मुख्य गड नरनाळा या नावाने ओळखला जात असून तेलियागड आणि जाफराबाद नावाचे दोन उपदुर्ग पूर्व-पश्चिमेला आहेत. गडाच्या प्रवेशाला ५ दरवाजे लागतात त्यांवरून या गडाच्या सुरक्षा व्यवस्थेची कल्पना यावी. सर्वात आधी शहानूर दरवाजा, मग मोंढा दरवाजा, त्यानंतर अत्यंत सुरेख कलाकुसर असलेल