@test是变量 select @xml.exist(N'//MasterxRow[position()=sql:variable("@test")]') 转载于:https://www.cnblogs.com/bulege/archive/2011/10/14/2212665.html