Description:
LOWER returns char, with all letters lowercase. char can be any of the datatypes CHAR, VARCHAR2, NCHAR, NVARCHAR2, CLOB, or NCLOB.
The return value is the same datatype as char.
Syntax:
Examples:
LOWER returns char, with all letters lowercase. char can be any of the datatypes CHAR, VARCHAR2, NCHAR, NVARCHAR2, CLOB, or NCLOB.
The return value is the same datatype as char.
Syntax:
LOWER(char)
Examples:
SELECT employee_id, last_name, department_id
FROM employees
WHERE last_name = 'higgins';
0 rows selected
The select statement displays the employee number, name, and
department number of employee Higgins.
The WHERE clause specifies the employee name
as higgins.
Because all the data in the EMPLOYEES table is stored in proper case, the name higgins does not find a match in the table,and no rows are selected.
SELECT employee_id, last_name, department_id
FROM employees
WHERE LOWER(last_name) = 'higgins';
SELECT first_name, job_id FROM EMPLOYEES
WHERE department_id = 60;
SELECT LOWER(first_name),LOWER(job_id) FROM EMPLOYEES
WHERE department_id = 60;
The WHERE clause specifies that the employee
name in the EMPLOYEES table is compared to higgins, converting the LAST_NAME column to lowercase for comparison
purposes.
Because both names are now lowercase, a match is found and one row is
selected.
WHERE department_id = 60;
The original data from EMPLOYEES table.
WHERE department_id = 60;
The same data using LOWER function.
No comments :
Post a Comment