دوال حرفية دوال رقميه دوال تاريخ دوال تحويل

Slides:



Advertisements
Similar presentations
Copyright  Oracle Corporation, All rights reserved. 2 Single-Row Functions.
Advertisements

Copyright © 2007, Oracle. All rights reserved Using Single-Row Functions to Customize Output Modified: October 21, 2014.
2 Restricting and Sorting Data Important Legal Notice:  Materials on this lecture are from a book titled “Oracle Education” by Kochhar, Gravina, and Nathan.
Restricting and sorting data 16 May May May Created By Pantharee Sawasdimongkol.
Subqueries 11. Objectives After completing this lesson, you should be able to do the following: Describe the types of problems that subqueries can solve.
Copyright  Oracle Corporation, All rights reserved. 6 Subqueries.
6 6 Subqueries Important Legal Notice:  Materials on this lecture are from a book titled “Oracle Education” by Kochhar, Gravina, and Nathan (1999), published.
Introduction to Oracle9i: SQL1 Selected Single-Row Functions.
Using Single-Row Functions to Customize Output
Lecture 6 29/1/15. Number functions Number functions take numbers as input, change them, and output the results as numbers. 2.
Logical Operators Operator AND OR NOT Meaning Returns TRUE if both component conditions are TRUE Returns TRUE if either component condition is TRUE Returns.
SQL Use of Functions Character functions Please use speaker notes for additional information!
Ch. 3 Single-Row Functions Important Legal Notice:  Materials on this lecture are from a book titled “Oracle Education” by Kochhar, Gravina, and Nathan.
Single-Row Functions. SQL Functions Functions are a very powerful feature of SQL and can be used to do the following: Perform calculations on data Modify.
3-1 Copyright  Oracle Corporation, All rights reserved. SQL Functions FunctionInput arg 1 arg 2 arg n Function performs action OutputResultvalue.
o At the end of this lesson, you will be able to:  Describe the life-cycle development phases  Discuss the theoretical and physical aspects of a relational.
Oracle FUNCTIONS. Comment ScreenShot (in 10g) General Example of null Foreign Key: create table deptcs( deptno NUMBER(4) primary key, hiredate DATE,
Ford 1. Ford 2 Ford 3 Ford 4 Ford 5 Ford 6 Ford 7.
Number Functions. 2 home back first prev next last Review single-row character functions –character case-manipulation functions  LOWER, UPPER, INITCAP.
3 Copyright © Oracle Corporation, All rights reserved. Single-Row Functions.
Chapter 10 Selected Single-Row Functions Oracle 10g: SQL.
Chapter 5 Selected Single-Row Functions. Chapter Objectives  Use the UPPER, LOWER, and INITCAP functions to change the case of field values and character.
Functions Oracle Labs 5 & 6. 2/3/2005Adapted from Introduction to Oracle: SQL and PL/SQL 2 SQL Functions Function arg n arg 2 arg 1. Input Resulting Value.
Dr. Philip Cannata 1 Programming Languages Prolog Part 3 SQL & Prolog.
3 Copyright © 2004, Oracle. All rights reserved. Using Single-Row Functions to Customize Output.
Single – Row Functions. Objectives After completing this lesson, you should be able to do the following:  Describe various types of functions available.
Subqueries.
Copyright  Oracle Corporation, All rights reserved. 3 Single-Row Functions.
Single Row Functions Week 2. Objectives –Describe types of single row functions in SQL –Describe and use character, number, date, general and conversion.
Oracle 11g: SQL Chapter 10 Selected Single-Row Functions.
SINGLE ROW FUNCTIONS 1. CHARACTER MANIPULATION Prof. Carmen Popescu Oracle Academy Lead Adjunct.
Chapter 3 Selected Single-Row Functions and Advanced DML & DDL.
Single Row Functions. Objectives –Use character, number, and date functions –Use conversion functions –Describe types of single row functions in SQL.
Single-Row Functions. SQL Functions FunctionInput arg 1 arg 2 arg n Function performs action OutputResultvalue.
Review SQL Advanced. Capabilities of SQL SELECT Statements Selection Projection Table 1 Table 2 Table 1 Join.
Copyright  Oracle Corporation, All rights reserved. 3 Single-Row Functions.
3 Copyright © 2009, Oracle. All rights reserved. Using Single-Row Functions to Customize Output.
Copyright س Oracle Corporation, All rights reserved. 3 Single-Row Functions.
3 Copyright © Oracle Corporation, All rights reserved. Single-Row Functions.
6 Copyright © Oracle Corporation, All rights reserved. Subqueries.
SQL Functions. SQL functions are built into Oracle Database and are available for use in various appropriate SQL statements. These functions are use full.
Built-in SQL Functions. 2 Type of Functions Character Functions returning character values returning numeric values Numeric Functions Date Functions Conversion.
Oracle CONNECT BY function JAVA WEB Programming. Emp 테이블의 내용 ( 상 / 하급자 계층구조 ) SQL> select * from emp; EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
2-1 Limiting Rows Using a Selection “…retrieve all employees in department 10” EMP EMPNO ENAME JOB... DEPTNO 7839KINGPRESIDENT BLAKEMANAGER CLARKMANAGER.
6 Subqueries. 6-2 Objectives At the end of this lesson, you should be able to: Describe the types of problems that subqueries can solve Define subqueries.
4/2/16. Ltrim() is used to remove leading occurrences of characters. If we don’t specify a character, Oracle will remove leading spaces. For example Running.
[ ] Square brackets enclose syntax options { } Braces enclose items of which only one is required | A vertical bar denotes options … Three dots indicate.
Copyright  Oracle Corporation, All rights reserved. 2 Restricting and Sorting Data.
3 Copyright © 2009, Oracle. All rights reserved. Using Single-Row Functions to Customize Output.
Defining a Column Alias
1 ORACLE I 3 – SQL 1 Salim Phone: YM: talim_bansal.
Copyright  Oracle Corporation, All rights reserved. 3 Single-Row Functions.
Single Row Functions Part I Week 2. Objectives –Describe types of single row functions in SQL –Describe and use character, number and date SQL functions.
مقدمة قواعد بيانات - أوراكل الفـصـل الــرابــع دوال الصف الواحد أ. جمانه الحازمي.
Enhanced Guide to Oracle 10g
Single-Row Functions Schedule: Timing Topic 55 minutes Lecture
Chapter 10 Selected Single-Row Functions Oracle 10g: SQL
Restricting and Sorting Data
الفصل الثالث فهم جمله الشرط where لحصر البيانات
SQL 101 3rd Session.
Using Single-Row Functions to Customize Output
الفصل الثاني الصيغة العامة لجمله select*
جملة الاستعلام الأساسية
المحاضرة 4 دوال الصف الواحد.
در تجزیه و تحلیل شغل باید به 3 سوال اساسی پاسخ دهیم Job analysis تعریف کارشکافی، مطالعه و ثبت جنبه های مشخص و اساسی هر یک از مشاغل عبارتست از مراحلی.
DATABASE SQL= Structure Query Language مبادئ قواعد بيانات
(SQL) Single-Row Functions
SQL 101 2nd Session.
Database Programming Using Oracle 11g
Presentation transcript:

دوال حرفية دوال رقميه دوال تاريخ دوال تحويل الفصل الرابع دوال حرفية دوال رقميه دوال تاريخ دوال تحويل T.Bedor

دوال حرفية هي دوال تتعامل مع البيانات الحرفية وتكون نتيجتها اما حرفية او رقاماً : وظيفتها الداله Function داله تستخدم لتحويل جميع الحروف الى حروف صغيره LOWER داله تستخدم لتحويل جميع الحروف الى حروف كبيره UPPER داله تستخدم لتحويل الحرف الاول الى حروف كبير وباقي الحروف صغيره INITCAP داله ربط من عمودين او سلسلتين تماما مثل ادا ربط (||) CONCAT داله تستخدم لقطع جزء من عمود او سلسله بدايه m ونهايه الحروف هي n SUBSTR داله تسخدم لايجاد عدد حروف (الناتج عدد ) LENGTH داله تسخدم لتحديد مكان حرف معين داخل عمود و الحرف m يعبر عن الحرف الموماج تحديد مكانه INSTR داله تستخدم لضبط بيانات عمود ناحيه اليمين وذلك بملء حرف معين من اليسار والحرف n لتحديد طول LPAD داله تستخدم لضبط بيانات عمود ناحيه اليسار وذلك بملء حرف معين من اليمين والحرف n لتحديد طول RPAD داله تستخدم لقطع حرف معين من بدايه او نهايه الكلمه فقط TRIM T.Bedor

المــــــثــــــــال مثال النتيجة المــــــثــــــــال good by select LOWER (‘GOOD by’) from dual ; GOOD BY select UPPER (‘GOOD by’) from dual ; Good select INITCAP (‘GOOD’) from dual ; GOODBY select CONCAT (‘GOOD ,By’) from dual ; OOD select SUBSTR (‘GOOD By’,2,3) from dual ; 4 select LENGTH (‘GOOD’) from dual ; select INSTR(‘GOOD ’,’D’) from dual ; *****AHMAD select LPAD (‘AHMAD,10,’*’) from dual ; AHMAD***** select RPAD (‘AHMAD,10,’*’) from dual ; AML select TRIM ( ‘S’ FROM ‘ SAML’) from dual ; T.Bedor

مثال SQL> select LOWER (ename), UPPER(job), INICAP(job), CONCAT(ename,job ) FROM emp Where sal =3000; job ename analyst Scott ford T.Bedor CONCAT(ename,job INICAP(job) UPPER(job) LOWER (ename) SCOTTANALYST analyst ANALYST Scott FORDANALYST ford