我正在尝试将以下查询从基于 SQL 服务器的代码转换为 TERADATA 代码。
INSERT INTO #Keyword(Keyword,OmnitureHitsID,Hit_Time_GMT)
SELECT Search, @PrvRowIdentity,Hit_Time_GMT
FROM
(SELECT
Evar02_Search
, Hit_Time_GMT
, Evar11_End_Keyword
, Evar14_End_SrchTrmPassed
, Post_Evar02
, Post_Evar11
, Post_Evar14
FROM #MaINTable WHERE ID = @i
AND Visid_High =@Visid_High ) p
UNPIVOT
(SEARCH FOR SearchKeyword IN
(Evar02_Search
, Evar11_End_Keyword
, Evar14_End_SrchTrmPassed
, Post_Evar02
, Post_Evar11
, Post_Evar14 )
) AS unpvt;
谁能告诉我如何在 UNPIVOT 之后转换零件。其实我不确定这SEARCH FOR SearchKeyword IN
部分是做什么的。
任何帮助表示赞赏:)