In this article, we will provide you with the Comprehensive notes on Perform operations on tables for Information Technology Class 10 .

Perform operations on tables for Information Technology Class 10

In this article, we will talk about insert data, edit records, delete records and sorting data in the table using LibreOffice Base. The first operation of Perform operations on tables for Information Technology Class 10 is insert record in the table.

Insert records in the table

Lets start this article with insert data into a table. You can insert data into table in two ways:

Perform operations on tables for Information Technology Class 10

Datasheet View

To insert data using datasheet view follow these steps:

Step 1 Open the database and select the table to insert a record.

Step 2 Now double click on the table name.

Open Office

insert records into table in datasheet view in oo base
insert records into table in datasheet view in oo base

LibreOffice

Open table to insert record Perform operations on tables for Information Technology Class 10

Step 3 A new screen appears with the title of table and database.

OpenOffice

insert data

LibreOffice

Table preview in datasheet view in libreoffice

Step 4 Now insert records in the last row. Observe the above screenshot.

Step 5 Save the table when you finished.

SQL Mode

To insert data using SQL mode follow these steps:

Step 1 > Open database.

Step 2 > Click on Tools > SQL. A new window appears with the title Execute SQL Statement.

Step 3 > Now type following command to insert record.

insert into "dept" ("dno","dname","loc") values (50,'TPP','Bhuj')

Step 4 >Now click on execute button and click on close button when you get the message “Command executed successfully. “

Step 5 > Click on close button.

Step 6 > Click View > Refresh Table option to see the updated table.

Observe the following screen shot:

insert into command in oo base
insert into command in oo base

You can avoid the column names if you are going to insert all records. Observe this command:

insert into "dept" values (60,'Hospital','Township')

The next operation is edit record operation for database table operations class 10.

Edit records in table

You can edit any records in similar two ways like datasheet view and SQL command.

Edit records in Datasheet view

Follow the below given steps:

Step 1 > Open your database to edit table.

Step 2 > Select your table and double click on it to open it.

Step 3 > Now place your cursor on the record which you want to edit.

Step 4 > Click on Edit > Edit Data or click on edit icon available on the standard toolbar or double click on data you want to edit.

Step 4 > Type the new data as you per requirement.

Step 5 > Save your records.

In the next section of database table operations class 10, we will see edit records through SQL.

Edit records through SQL

Open Execute SQL statement window. and type following command:

update "dept" set "deptno"=100 where "deptno"=10

The update command is used to edit records through SQL command. As you have seen in the above command –

  • update – is a command to edit records
  • tablename – it is a table in which the record needs to be updated
  • set – This is a keyword used to set a new value
  • columnname = new value – it is a columnname with new value
  • where – it specifies the unique record of the table which is going to be deleted
  • columnname = value – here the columnname is the column which is having a unique record and the value is a unique value

The next operation is delete records in database table operations class 10.

Delete records from the table

You can delete records from the table using datasheet view and execute SQL statement window. Open the database and table in datasheet view and open the table from you want to delete the record.

Delete record in datasheet view

Place your cursor on the record in the table and do one of the following:

  1. Click on Edit > Delete Record option. It will ask your confirmation to delete selected data with “Yes”/“No” button.
  2. Do Right-click and select delete option.
  3. Select the entire row, do right-click and choose the option Delete Rows and click on “Yes” button to confirm deletion.

Delete record using SQL view

Open Execute SQL statement window and write the following command:

delete from "dept" where "deptno"=100

It is almost similar like update with one difference that is, use delete from tablename command.

In the next section of database table operations class 10 we will see the common field properties for the OO base tables.,

Common field Properties

Field properties are useful to restrict or enable data validation in the table.

Data Validation refers to the set of rules and regulation for data input. So that incorrect data or invalid data can be avoided in the table.

To change the properties follow these steps:

  1. Open your database and select the table to change the properties.
  2. Right-click on a table and select edit option or Click on Edit > Edit option. That opens the table in design view.
  3. Now select the particular field to change the properties.

The common properties are as following:

  1. AutoValue – It provides Yes/No type option to accept the value automatically at the time of insertion.
  2. Entry Required – It is also Yes/No type option to make the field value mandatory at the time of insertion.
  3. Length – This option is used to specify the total length of the selected field.
  4. Default Value – This option provides a default value to your field if value is not inserted.
  5. Format Example – It allows to set your own format for the field values like email format, zip code format etc.

Lets talk about sorting data, as it is next topic given in your syllabus for database table operations class 10.

Sorting Data

As you know that sorting rearranges the data in an ascending or descending order. To sort data in OO Base, follow these steps:

Step 1 > Select the column which you want to sort.

OpenOffice

Sorting options in OO Base
Sorting options in OO Base

LibreOffice

Sorting Data in the libreoffice base table datasheet view

Step 2 > Now click on appropriate button from the toolbar as highlighted in above screen shot. Your datasheet displays the result accordingly.

In the next article, we will discuss about the referential integrity.

I hope you enjoyed this article and understood the concepts of database table operations class 10 in OO Base explained in this article. If you have any doubt or queries regarding this article, you are free to ask through comments.

Follow this link to get important questions on performing table operations.

Important questions perform table operations in base

Thank you for reading this article database table operations class 10. Share this article with your classmates and friends. Motivate us by hitting the like button to provide more and more concise and detailed study material.

2 thoughts on “Comprehensive notes on Perform operations on tables for Information Technology Class 10”
  1. G. subashini says:

    pls send the important question for board exams in unit Database management system for class x code 402 IT

Leave a Reply