我想将查询转换为 sql server 上的视图。SS 迁移助手正在处理以下查询:
SELECT
FechInventory.ID AS skuID,
FechInventory.ItemNo,
IIf(InStr(3,[ItemNo],".")>0,Mid([ItemNo],3,InStr(1,[ItemNo],".")-3),InStr(3,[ItemNo],Len([ItemNo]))) AS ItemStyle,
IIf(InStr(1,[ItemNo],"/")>0,Mid([ItemNo],InStr(1,[ItemNo],".")+1,InStr(1,[ItemNo],"/")-InStr(1,[ItemNo],".")-1),Mid([ItemNo],InStr(1,[ItemNo],".")+1,Len([ItemNo]))) AS Size1,
IIf(InStr(1,[ItemNo],"/")>0,Mid([ItemNo],InStr(1,[ItemNo],"/")+1,Len([ItemNo])-InStr(1,[ItemNo],"/")),"") AS Size2,
FechInventory.Desc,
FechInventory.Qty,
FechInventory.sCost,
[sCost]*0.18 AS gcCost,
[scost]*0.18*[qty] AS gcLineCost,
InStr(3,[ItemNo],".") AS FirstPeriod,
InStr(1,[ItemNo],"/") AS FirstSlash,
Len([ItemNo]) AS ItemNoLength,
FechInventory.Brand,
Brands.[Brand Name],
FechInventory.ProductType,
ProductTypes.ProductTypeName,
FechInventory.Gender,
Genders.GenderName,
FechInventory.Sleeve,
SleeveLengths.SleeveLength,
FechInventory.Color,
Colors.ColorName,
Fabrics.FabricTypeID,
Fabrics.FabricName
FROM
(
Colors
RIGHT JOIN
(
SleeveLengths
RIGHT JOIN
(
Genders
RIGHT JOIN
(
(
FechInventory
LEFT JOIN
Brands
ON FechInventory.Brand = Brands.BrandID
)
LEFT JOIN
ProductTypes
ON FechInventory.ProductType = ProductTypes.ProductTypeID
)
ON Genders.GenderID = FechInventory.Gender
)
ON SleeveLengths.SleeveID = FechInventory.Sleeve
)
ON Colors.ColorID = FechInventory.Color
)
LEFT JOIN
Fabrics
ON FechInventory.FabricType = Fabrics.FabricTypeID
ORDER BY FechInventory.ItemNo;
它给出了这个错误:
- SSMA 错误消息:
- A2SS0058:以下 SQL 语句不受支持且无法转换:
是什么赋予了?有什么突出的吗?