能够弄清楚。这不是数据问题,所以有点棘手。轮到我可能有一个不需要的额外选择。
这是我的工作代码的代码示例:
DECLARE @ReportTitle as VARCHAr(100) (SELECt @ReportTitle = REPLACE(T1.Title, 'Sale', '') FROM dbo.tblSales ti WHERe t1.IdCountry = 34 AND t1.IdReport = 214 AND t1.IdLanguage= 1 and t1.btInUse = 1)SELECt i.IdCountry as Country, i.Title as ReportTitle, i.Report as IndustryIDFROM dbo.tblSales iWHERe i.IdCountry = 21 AND i.IdLanguag = 1 and i.btInUse = 1 AND i.Title LIKE '%' + @ReportTitle +'%'



