Page 14 - 2501_KVS_C-8
P. 14

The given image will show some of the common data types used in table in Base of LibreOffice:




































                  Some of the important data types are discussed here:

                   Data Type                   Type of Values that may be stored
                   Text [ Varchar ]            Text values such as alphabets or numbers or special characters

                   Number [ NUMERIC ]          Only Numbers or Numeric values

                   Integer [ INTEGER ]         Only integer both positive and negative
                   Decimal [ DECIMAL ]         Decimal (fractional) numbers with fixed precision
                   Float [ FLOAT ]             Decimal (fractional) numbers with floating-point precision

                   Date [DATE]                 Stores date values

                  1.6  PRIMARY KEY IN A TABLE

                      Primary Key: A Primary key is that column or a field which is used to identify unique
                       values in a table. It is very important to get accurate information from thousands of
                       records stored in a table.

                  Let us understand the primary key with an example. For example, we have 5 records of 5
                  students in the above table of students. In the table, 2 students have the same name. Then
                  how can one can identify the correct student in the table? Therefore, we must have such a
                  column in the table that must identify the unique record among any number of records like
                  “ADMNO” given in the above table Student. Here ADMNO can be said to be a primary key
                  to identify each record differently.






                12                         KVS DELHI REGION 2025
   9   10   11   12   13   14   15   16   17   18   19