Homechevron_rightEngineeringchevron_rightRPSC Programmerchevron_rightProgrammer DBMSchevron_right<p class="MsoNormal" style="margin left:0in;text ind...

...

  • Q.

    Consider a relational database containing the following schemes.

    Catalogue

    sno

    pno

    Cost

    S1

    P1

    150

    S1

    P2

    50

    S1

    P3

    100

    S2

    P4

    200

    S2

    P5

    250

    S3

    P1

    250

    S3

    P2

    150

    S3

    P5

    300

    S3

    P4

    250

     

    Suppliers

    sno

    sname

    location

    S1

    M/s Royal furniture

    Delhi

    S2

    M/s Balaji furniture

    Bangalore

    S3

    M/s Premium furniture

    Chennai

     

    Parts

    pno

    Pname

    Part_spec

    P1

    Table

    Wood

    P2

    Chair

    Wood

    P3

    Table

    Steel

    P4

    Almirah

    • filter_dramaExplanation
      Answer is : A

      Inner Query: SELECT AVG (cost) FROM Cataloque WHERE pno = ‘P4’ GROUP BY pno

      The execution of the inner query gives the average of the cost of parts with part-id P4

      Output:

      Avg (cost)

      225

       

      Outer Query:

      SELECT s.sno, s.sname FROM Suppliers s, Cataloque c WHERE s.sno = c.sno AND Cost > (225)

      The execution of the entire query output the following table:

      sno

      sname

      S2

      M/s Balaji furniture

      S3

      M/s Premium furniture

      S3

      M/s Premium furniture

      S3

      M/s Premium furniture

       

      Hence, there are 4 rows in the resultant table. 

    Discussion

      No one started the discussion yet. Break the ice and start the conversation.
      Please Login to be part of the discussion.

    Similar Questions

    • 1.

      What are the fields that packet filter network firewall can investigate and block the user using it?

      I. Port number of users

      II. IP address of users

      III. MAC address of users

    • filter_dramaExplanation
      Answer is : B

      Concept:

      • Packet filter firewall can investigate up to network layer
      • Packet filter firewall cannot investigate in transport layer section hence cannot block user with a specified port number

       

      Transport layer

      (Port Number)

      Network Layer

      (IP address)

      Data Link Layer

      (MAC Address)

      Physical Layer

       

      Explanation:

      A packet filter network firewall can investigate and block network traffic based on several fields in a network packet header.
      These fields include:

      I. the source and destination port numbers.

      II. the source and destination IP addresses.

      Additional InformationMAC addresses are included in the packet header, they are typically used for local network communication and are not used for filtering traffic by a packet filter firewall.

      Note: However, some advanced firewalls may be able to filter traffic based on the MAC address in certain scenarios, such as in virtualized environments or for wireless access points.

      Hence, the correct answer is option 2.

    • 2.

      Consider the following statements:

      Statement 1: The two-phase locking protocol ensures conflict serializability and ensures freedom from deadlock.

      Statement 2: With rigorous two-phase locking, transactions cannot be serialized in the order in which they commit.

      Statement 3: Strict two-phase locking requires not only that locking is two-phase, but also that all exclusive-mode locks taken by a transaction be held until that transaction commits.

      Which of the given statements is/are false?

    • filter_dramaExplanation
      Answer is : A

      Answer: Option 1

      Explanation:

      The correct answer is option 1 i.e. both S1 and S2 are false.

      Statement 1: The two-phase locking protocol ensures conflict serializability and ensures freedom from deadlock.

      This Statement is not true. because The two-phase locking protocol ensures conflict serializability but does not ensure freedom from deadlock.

      Statement 2: With rigorous two-phase locking, transactions cannot be serialized in the order in which they commit.

      This Statement is not true. With rigorous two-phase locking, transactions can be serialized in the order in which they commit.

      Statement 3: Strict two-phase locking requires not only that locking is two-phase, but also that all exclusive-mode locks taken by a transaction be held until that transaction commits.

      This Statement is true. this is the definition of the Strict 2-Phase protocol.

    • 3. What do data warehouses support?  
    • filter_dramaExplanation
      Answer is : A

      Concept:

      Data warehouse is the process of collecting aand managing the data from different sources and use them for a business purpose. It is more related to query processing rather than transaction processing.

      Explanation:

      Data warehouse usually contains historical data concluded from transactional data. A data warehouse includes ETL(extraction, transformation, and loading) , OLAP engine, other tools that manages the collection of data and deliver this data to business users. A data warehouse is an example of OLAP system. 

      OLAP (Online analytical processing) system helps in analyzing the data. It allow analysts to efficiently answer questions that require data from multiple source systems.

      Diagram : 

      Description of Figure 1-3 follows

    • 4.

      If the message contains only one bit and network contains a single link, and then latency corresponds to the _______

    • filter_dramaExplanation
      Answer is : D

      The amount of time taken to transmit a unit of data is called transmission time.

      Propagation delay corresponds to how long it takes a message to travel from one end of a network to the other.

      Queuing time is the time needed for each intermediate or end device to hold a message before it can be processed.

      If the message contains only one bit and we are talking about a single link (as opposed to a whole network), then the Transmit and Queue and processing time terms are not relevant, and latency corresponds to the propagation delay only.
    • 5.

      Match the following algorithms to their key sizes.

      a) RSA (Rivest–Shamir–Adleman) i) 56 bits
      b) International Data Encryption Algorithm (IDEA) ii) 128, 192, or 256 bits
      c) Advanced Encryption Standard (AES) iii) 1024-or 2048-bits
      d) Data Encryption Standard (DES) iv) 128 bits
    • filter_dramaExplanation
      Answer is : C
      Key Points
      •  Asymmetric cryptography, also known as public-key cryptography, is a process that uses a pair of related keys, one public key.
        • RSA (Rivest–Shamir–Adleman) keys tend to be 1024 or 2048 bits in length, making them extremely difficult to factorize.
      • Symmetric cryptography is a type of encryption where only one key (a secret key) is used to both encrypt and decrypt electronic information.
        • IDEA is symmetric cryptography that operates on 64-bit blocks using a 128-bit key and consists of a series of 8 identical transformations.
        • Advanced Encryption Standard (AES) keys are symmetric keys that can be three different key lengths (128, 192, or 256 bits).
        • DES is insecure due to the relatively short 56-bit key size.

      Hence the correct answer is a-iii, b-iv, c-ii, d-i.

    Programmer DBMSTopics

    leaderboardLeaderboard
    • Rahul Kumar

      191 Points

    • VIKRAM JEET

      54 Points

    • GEETHIKA CHOWDARY

      53 Points

    • sunita saini

      52 Points

    • Zain

      49 Points