我的脚本返回错误:消息102,级别15,状态1,第10行 '('附近的语法不正确。
在SSMS中执行脚本后,为什么我的脚本不显示数据透视表?
我只需要在SSRS上运行此VBA脚本?
select * from(
select
Vendor_ID.col1
,Employee_Status.col2
,row_number() OVER (ORDER BY DESCRIPTION) AS 'rowNumber'
(partition by Vendor_ID order by Employee_Status) as Employee_Status
from dbo.Vendors_Employees
group by Vendor_ID
,Employee_Status
)t1
PIVOT
(
MAX(Vendor_ID)
FOR Employee_Status in ([1],[2])
)piv