34 | How to use CONVERSION FUNCTION in ORACLE SQL | Oracle PL/SQL Programming

Опубликовано: 26 Май 2022
на канале: Book Of Infinity
51
3

Besides the SQL utility functions, Oracle inbuilt function library contains type conversion functions. There may be scenarios where the query expects input in a specific data type, but it receives it in a different data type. In such cases, Oracle implicitly tries to convert the unexpected value to a compatible data type which can be substituted in place and application continuity is not compromised. Type conversion can be either implicitly done by Oracle or explicitly done by the programmer.

Implicit data type conversion works based on a matrix which showcases the Oracle's support for internal type casting. Besides these rules, Oracle offers type conversion functions which can be used in the queries for explicit conversion and formatting. As a matter of fact, it is recommended to perform explicit conversion instead of relying on software intelligence. Though implicit conversion works well, but to eliminate the skew chances where bad inputs could be difficult to typecast internally.

Practically there are two types of Conversion Functions
1. Implicit
and
2. Explicit

34 | How to use CONVERSION FUNCTION in ORACLE SQL (Part-2) | Oracle PL/SQL Programming

#conversion_function_sql #implicit_function #explicit_function