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

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 816
    Comment on it

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

       Basically, SQL Max () Function is used to get the maximum value from the selected field.

        Syntax of SQL Max () Function :

       

     select max (column_name) from table_name;

    Example :
    Table name : Empl_Info

        Id  Employee_name   Employee_Age   Employee _Salary
        1    Deepak                     25                      150000
        2    Manoj                       24                       220000
        3    Uday                        20                       300000
        4    Pradeep                   35                       125,00000
        5    Abhishek                 26                       820000
        6    Ravi                         25                       300000

    Now we want find the Highest salary of employee list.  

    Then we will use below query

       

    select max ( Employee_Salary ) as Highest_Salary from Empl_Info ;

    Output :

        Highest_Salary
        125,00000

     

 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: