Articles in this section
Category / Section

How to Change Column Data Type in Code View Mode for MS SQL and Postgre SQL connections

Published:

In Code View mode, you can change the data type of a column using different methods depending on the data source you are using. Here, we provide examples for Microsoft SQL and PostgreSQL data sources.

Microsoft SQL

To convert a string to an int in a Microsoft SQL data source, use the following syntax:

CONVERT(datatype, Column_name)

image.png

Alternatively, you can use an expression to achieve the same result.

image.png

PostgreSQL

To convert a string to an int in a PostgreSQL data source, use the following syntax:

CAST(Column_name AS INT)

image.png

For a PostgreSQL data source, you can also use an expression to convert the data type.
image.png

Additional References

Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
IJ
Written by Israel Jebaraj Chandirakumar
Updated
Comments (0)
Please  to leave a comment
Access denied
Access denied