Page 192 - IT-802_class_12
P. 192

30.  Sukhdev has created a relation Teacher (Teacher_ID, Fire_Name, Last_Name, Gender, Date_of_Birth. Salary, Dept_No). Help
             him to identify the correct query to display all the records of Teacher with no last name.    [2022]
              (a)  Select *from Teacher where First name is not null.
              (b)  Select *from Teacher where Last_name=NULL.
              (c)  Select *from Teacher where Last_name is NULL.
              (d)  Select *from Teacher where Last name= is NULL.
         Ans.  (b)  Select *from Teacher where Last_name=NULL.
          31.  Ishu created a relation ‘Sales’ and now he wants to add tuples in the relation. Identify the type of command and the
             command name from the following:                                                              [2022]
              (a)  DDL.,add                                (b)  DML.,insert
              (c)  DDL.,insert                             (d)  DML.,add
         Ans.  (b)  DML.,insert
          32.  Consider a table ‘Flights’ with fields (Flight_ID, Start, Destn, Seats, Cost,) Select the command to find average price of all the
             flights from source ‘Delhi’ to destination ‘Mangalore’.                                       [2022]
              (a)  Select average(cost) from Flights where start=’Delhi’, Destn=’Mangalore’;
              (b)  Select avg(cost) from Flights where start=’Delhi’, Destn=’Mangalore’;
              (c)  Select avg(cost) from Flights where start=’Delhi’ and Destn=’Mangalore’;
              (d)  Select average(cost) from Flights where start=’Delhi’ and Destn=’Manglore’;
         Ans.  (b)  Select avg(cost) from Flights where start=’Delhi’, Destn=’Mangalore’;
          33.  Consider following tables:                                                                  [2022]
             Product:
                  IP_ID       Prod_name        Price          Qty           ROL           Brand

                  P111      Keyboard          650.00          50             10       Simtronics
                  P123      Monitor           250.00          100            10       Intex
                  P101      Wifirouter        1200.00         50             5        Zevronics

                  P003      Keyboard          120.00          150            15       Simtronics
                  P104      CDROM              10.00          200            25       Zebronics
                  P112      Speaker           450.00          50             4        Intex

                  P231      Mouse             300.00          50             5        Zebronics
             Supplier:
                 Sup_ID          P_ID              S_name                  City

                  S110           P111       Ganesha Electricals   Delhi
                  S101           P112       Ramesh Tronics        Bhopal

                  S114           P111       Simmi Works           Chandigarh
                  S116           P003       Sumeet Suppliers      Vadodara
                  S120           P123       Ziaz comps            Lucknow

                  S210           P104       Simtex                Delhi
                  S432           P101       D Electricals         Sonipat








          190   Touchpad Information Technology-XII
   187   188   189   190   191   192   193   194   195   196   197