Informatics Practices
A table "TRAINS" in a database has degree 3 and cardinality 8. What is the number of rows and columns in it ?
SQL Joins & Grouping
3 Likes
Answer
The "TRAINS" table in the database has a degree of 3, indicating it contains three attributes or columns and it has a cardinality of 8, indicating it consists of eight rows or tuples. Therefore, the "TRAINS" table has 8 rows and 3 columns.
Answered By
2 Likes
Related Questions
How is a left join different from a natural join ? Give example.
How is a cross join different from natural join ? Give example.
In a database there are two tables "Product" and "Client" as shown below :
Table : Product
P_ID ProductName Manufacture Price P001 Moisturiser XYZ 40 P002 Sanitizer LAC 35 P003 Bath Soap COP 25 P004 Shampoo TAP 95 P005 Lens Solution COP 350 Table : Client
C_ID ClientName City P_ID 01 Dreamz Disney New Delhi P002 05 Life Line Inc Mumbai P005 12 98.4 New Delhi P001 15 Appolo Banglore P003 Write the commands in SQL queries for the following :
(i) To display the details of Product whose Price is in the range of 40 and 120 (Both values included).
(ii) To display the ClientName, City from table Client and ProductName and Price from table Product, with their corresponding matching P_ID.
(iii) To increase the Price of all the Products by 20.
In a Database School there are two tables Member and Division as shown below.
Table : Member
EmpId Name Pay Divno 1001 Shankhya 34000 10 1003 Ridhima 32000 50 1002 Sunish 45000 20 Table : Division
Divno Divname Location 10 Media TF02 20 Dance FF02 30 Production SF01 (i) Identify the foreign key in the table Member.
(ii) What output, you will get, when an equi-join query is executed to get the NAME from Member Table and corresponding from Division table ?