Get the App
SLTechnology News&Howtos  ›  Database  › 

Implicit conversion between different data types

Shulou Source: shulou.com Published: 2022-06-01 15:18:11 09月30日 Update

Implicit conversions between data types in assignment statements

Convert variable-length characters (varchar2) or fixed-length characters (char) to numeric types (NUMBER)

Convert variable-length characters (varchar2) or fixed-length characters (char) to date types (DATE)

Convert numeric (NUMBER) to variable-length character (varchar2)

Convert date type (DATE) to variable length character type (varchar2)

Implicit conversion of data types in expressions

Convert variable-length characters (varchar2) or fixed-length characters (char) to numeric types (NUMBER)

Convert variable-length characters (varchar2) or fixed-length characters (char) to date types (DATE)

Data of numeric type (NUMBER) and data of date type (DATE) cannot be converted directly. One of the data types must be converted to character type first, and then the character type must be converted to the other data type.

Tags: Characters character types data types dates fixed lengths between fonts fractions numbers expressions statements different Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information Apple Redmi vpn MySQL