len()函数len(字符串或者字符型字段)select len(dept_name) from dept或者declare @length set @length = len('dfjljkalfdja')
len(字段名) select len('abc')输出3select len('abcde')输出5