Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to use SQL Min () Function ?

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 664
    Comment on it

    Hi Reader's,
      Welcome to FindNerd, today we are going to discuss how to use   SQL Min () Function in Sql.

    SQL Min () Function is used for getting the minimum value from the selected field.

    Syntax of SQL Min ():

     select min (column_name) from table_name;

    Example of SQL Min () Function:
    Firstly create a table
    Table name : Empl_Info

       Id      Empl_name            Empl_Age        Empl_Salary
        1        Deepak                      23                   15000
        2        Manoj                         24                   22000
        3        Uday                          25                   45000
        4        Pradeep                     35                   125,000
        5        Shiva                         28                   850000
        6        Ravi                           25                   300000
        7        Sanjay                       40                   80000

    Now we want find the min salry of employee list.  

    Then we will use below query

     SELECT MIN(Empl_Salary) AS Lowest_Salary FROM Empl_Salary

    Output :
        Lowest_Salary
          15000

     

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: