0% found this document useful (0 votes)
21 views8 pages

Oracle String and Date Functions Guide

The document provides an overview of beginner-level inbuilt functions in Oracle Database, focusing on string and date manipulation functions for junior developers. It highlights common string functions like UPPER, LOWER, and SUBSTR, as well as date functions such as SYSDATE and ADD_MONTHS, with examples for each. The document emphasizes the efficiency and practicality of these functions in real-world scenarios, such as data cleaning and scheduling.

Uploaded by

anoopr9999
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views8 pages

Oracle String and Date Functions Guide

The document provides an overview of beginner-level inbuilt functions in Oracle Database, focusing on string and date manipulation functions for junior developers. It highlights common string functions like UPPER, LOWER, and SUBSTR, as well as date functions such as SYSDATE and ADD_MONTHS, with examples for each. The document emphasizes the efficiency and practicality of these functions in real-world scenarios, such as data cleaning and scheduling.

Uploaded by

anoopr9999
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd

Beginner Level Inbuilt Functions

in Oracle Database
Focus on String and Date
Manipulation Functions
Training for Junior Developers
Introduction to Oracle Functions
• • Inbuilt functions simplify SQL queries
• • Useful for manipulating strings, numbers,
and dates
• • Improve efficiency and readability
• • Today: Focus on String and Date functions
String Functions Overview
• Common string functions:
• • UPPER(str) – Converts text to uppercase
• • LOWER(str) – Converts text to lowercase
• • INITCAP(str) – Capitalizes first letter of each
word
• • LENGTH(str) – Returns length of string
• • SUBSTR(str, start, length) – Extracts part of
string
• • INSTR(str, substring) – Finds position of
Examples of String Functions
• Example 1: UPPER
• SELECT UPPER('oracle') FROM dual; → ORACLE

• Example 2: SUBSTR
• SELECT SUBSTR('HelloWorld', 1, 5) FROM dual;
→ Hello

• Example 3: INSTR
• SELECT INSTR('HelloWorld','W') FROM dual; →
Date Functions Overview
• Common date functions:
• • SYSDATE – Current system date and time
• • ADD_MONTHS(date, n) – Add n months
• • MONTHS_BETWEEN(date1, date2) –
Difference in months
• • NEXT_DAY(date, 'DAY') – Next occurrence of
a weekday
• • LAST_DAY(date) – Last day of the month
• • ROUND(date, 'fmt') – Rounds date to
Examples of Date Functions
• Example 1: SYSDATE
• SELECT SYSDATE FROM dual; → 23-SEP-25

• Example 2: ADD_MONTHS
• SELECT ADD_MONTHS(SYSDATE, 2) FROM
dual;

• Example 3: MONTHS_BETWEEN
• SELECT MONTHS_BETWEEN('01-SEP-25','01-
Real World Use Cases
• • String functions – Cleaning and formatting
user data
• Example: Validating email addresses,
formatting names

• • Date functions – Calculating deadlines,


schedules
• Example: Finding due dates, last day of
billing cycle
Summary
• • Inbuilt functions save time and effort
• • String functions help with text manipulation
• • Date functions handle scheduling and time
logic
• • Practice with examples to master usage

You might also like