日期:2014-05-17  浏览次数:20752 次

如何找出A字段数据长度最长的那条记录
如何找出A字段数据长度最长的那条记录

------解决方案--------------------
select * from
(
select table_name.*, row_number()over(order by length(column_A) desc) as rn
from table_name
)
where rn = 1

------解决方案--------------------
select * from table_name where column_name = (select max(column_name) from table_name)