Search
 
SCRIPT & CODE EXAMPLE
 

SQL

min max sql

SELECT MIN(salary), MAX(salary) FROM employees;
SELECT team, MIN(salary), MAX(salary) FROM employees GROUP BY team;
Comment

sql max min

select emp_name, salary
from employees
where salary = (select max(salary) from employees)
union all
select emp_name, salary
from employees
where salary = (select min(salary) from employees);
Comment

min max in sql

SELECT MIN(column_name),
MAX(column_name),
AVG(column_name)
FROM table_name
WHERE condition;
Comment

SQL MAX() and MIN() with Strings

SELECT MIN(first_name) AS min_first_name
FROM Customers;
Comment

PREVIOUS NEXT
Code Example
Sql :: delphi split datetime 
Sql :: sqlite referential integrity 
Sql :: cube oracle 
Sql :: How to make PHP handeling my "WITH CTE as" SQL 
Sql :: db connection using sql client in dot net 
Sql :: oracle apex call duration 
Sql :: flush user resource mysql 
Sql :: cursors in db2 
Sql :: select all fron table 
Sql :: python sqlalcahmey compare datetime 
Sql :: sql create text column limited values 
Sql :: postgresql Change role for the current session to the new_role 
Sql :: <connectionStrings <add name="MainDB" connectionString="Data Source=multidc02.its.com.pk,47328;Initial Catalog=ITSGeneralApplications;User ID=ITSGeneralAdmin;Password=TDsHn6TTyJohXCe"/ </connectionStrings 
Sql :: sql Contain declare sample 
Sql :: radius search with point data in mysql 
Sql :: sql select random procentage from rows 
Sql :: APEX elapsed time 
Sql :: how to know which table has more data oracle sql 
Sql :: TSQL Code Snippet For Optimized Sales Query 
Sql :: oracle procedure chain step 
Sql :: Second Step in installing SQL workbench 
Sql :: child row: a foreign key constraint fails 
Sql :: run all sql file from folder postgres command line 
Sql :: get the next column of a table in mysql 
Sql :: restarting of postgresql server when not connecting to default port 
Sql :: unable to open database database.db file is encrypted or is not a database 
Sql :: C# get column name of sqlreader 
Sql :: extract sql from query object sqlalchemy 
Sql :: suse start MySQL 
Sql :: undefined get_magic_quotes_gpc() in sqlite 
ADD CONTENT
Topic
Content
Source link
Name
4+8 =