日期:2014-05-17 浏览次数:20612 次
select cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),1,40) as varchar(40)) f1, datalength( cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),1,40) as varchar(40)) ) f2, cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),41,40) as varchar(40)) f3, datalength( cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),41,40) as varchar(40)) ) f4, cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),81,40) as varchar(40)) f5, datalength( cast(substring(cast('一副接W头/PCS' as varbinary(400)) + cast(space(400) as varbinary(400)),81,40) as varchar(40)) ) f6 ----------------- f1 f2 f3 f4 f5 f6 ---------------------------------------- ----------- ---------------------------------------- ----------- ---------------------------------------- ----------- 一副接W头/PCS 40 40 40 (1 行受影响)