Tuesday 28 June 2016

Get max length of data for a column in Oracle


There is a situation where a column of varchar type max length is 50. what my requirement is to know the max and min length of the data stored in that column.

Here are the queries:

Max Length of data:

Select max(length(your_col_name)) as max_length From your_table_name;

Min Length of data:

Select min(length(your_col_name)) as max_length From your_table_name;


No comments:

Post a Comment