HomeНаука и техникаRelated VideosMore From: Tech Query Pond

Oracle tutorial : Conversion Functions In Oracle

17 ratings | 3746 views
Oracle tutorial : Conversion Functions In Oracle. oracle tutorial for beginners sql convert This Oracle tutorial video will show how to use conversion function in sql oracle TO_CHAR() , TO_DATE() , TO_NUMBER() these are mostly used functions. Conversions functions are used to convert one data type to another type. 1)To_CHAR ( number | date, [fmt], [nlsparams] ) The TO_CHAR function converts the number or date to VARCHAR2 data type in the specified format (fmt). 2)TO_NUMBER( char, [‘fmt’] ) The TO_NUMBER function converts the characters to a number format. 3)TO_DATE( char, [‘fmt’] ) The TO_DATE function converts the characters to a date data type. — TO_CHAR() fmYYYY YYYY/MM/DD SELECT TO_CHAR(SYSDATE, ‘YYYY/MM/DD’) FROM DUAL; — SO USING TO_CHAR U CAN GET FORMATE OF DATE ACCORDING TO UR REQURMENTS —- $99,999 99.99 99,00 SELECT TO_CHAR(487, ‘$99,0’) FROM DUAL; — U CAN GET DATA IN CURRENCY FORMAT —- TO_NUMBER() SELECT TO_NUMBER(‘1745′,’99999’) FROM DUAL; SELECT TO_NUMBER(‘1,47,982′,’9,99,999′) FROM DUAL; —- TO_DATE() — THIS CONVERT VARCHAR DATE TO PROPER DATE FORMAT SELECT TO_DATE(’30-JAN-1995′,’DD-MON-RRRR’) FROM DUAL; For more tutorial please visit #techquerypond https://techquerypond.com https://techquerypond.wordpress.com https://twitter.com/techquerypond sql convert convert function in sql
Html code for embedding videos on your blog
Text Comments (0)

Would you like to comment?

Join YouTube for a free account, or sign in if you are already a member.