SRM eLab Solutions
  • Home
  • About
  • Contact
  • Home
  • DBMS 2021
  • _Session - 1
  • _Session - 2
  • _Session - 3
  • _Session - 4
  • _Session - 5
  • _Session - 6
  • _Session - 7
  • _Session - 8
  • _Session - 9
  • _Session - 10

Ad Code

DBMS - SECTION 5 - SQL Functions - 2

 

  • UCASE - UPPER.
  • ASCII - Value.
  • SUM of CITY Table.
  • Now Function - Scalar Function.
  • Round and Square root Function.
  • MID FUNCTION - SCALAR FUNCTION - NAME column.
  • Sign Mathematical Functions.
  • MID FUNCTION - SCALAR FUNCTION - Column Salary.
  • LCASE - LOWER.
  • Round, Power and Square root Function.

Post a Comment

2 Comments

  1. AnonymousAugust 9, 2024 at 8:22 AM

    QUESTION
    SESSION NAME:SQL Functions - 2
    QUESTION NAME: Round, Power and Square root Function
    TABLE DESCRIPTION
    In this task, the user needs to write a query to implement Round, Power and Square root function.

    Note: Use SQL in-built Function to calculate round, power and square root function for station table.

    The user needs to implement round, power and square root function for the column lat_n and long_w and ID in customers table

    Round the lat_n method to TWO digits.

    1. Hint: round(lat_n , 2).

    2. For power function :

    Use lat_n value as one parameter "x" value and the "y" as 5.
    Note: power(x,y) X= value denoted , lat_n and Y denotes="5"

    Use long_w value as one parameter "x" value and the "y" as 7.
    Note: power(x,y) X= value denoted , long_w and Y denotes="7"

    3. Square root function for column ID.

    Input Format

    The station table is described as follows:

    ReplyDelete
    Replies
      Reply
  2. AnonymousAugust 24, 2026 at 6:46 AM

    SESSION NAME:SQL Functions - 2
    QUESTION NAME: MID FUNCTION - SCALAR FUNCTION - NAME column
    TABLE DESCRIPTION
    MID Function:

    MID Function has three parameters:

    First Parameter = Column Name
    Second Parameter = Start Length
    Third Parameter = Length of characters to be displayed
    Note: Index starts from 1.

    Example:

    MID(column_name, start, length) from table-name;

    Write a FUNCTION to display the name column of employee table using mid function.

    The start length (index) is 1 and display total of 3 characters in name column.

    Table Name : emp
    Columns

    eid - Number
    name - varchar
    age - Number
    salary - Number

    ANSWER:

    select mid(name,1,3)from emp;

    ReplyDelete
    Replies
      Reply
Add comment
Load more...

Search This Blog

Tags

  • DBMS
  • Session-1
  • Session-10
  • Session-2
  • Session-3
  • Session-4
  • Session-5
  • Session-6
  • Session-7
  • Session-8
  • Session-9

Categories

Ad Code

SRM eLab Solutions

"People who copy you will always be one step behind"

Footer Menu Widget

  • Home
  • About
  • Contact Us
Designed with by Way2Themes | Distributed By Gooyaabi Themes