![]() |
|
Archives of the TeradataForumMessage Posted: Wed, 04 Jan 2006 @ 12:35:09 GMT
Hi, Req : To convert Rows into Columns for CHAR Attribute When we where try to use OLAP function to get the max from CHAR/VARCHAR Attribute, we were getting 3617: Format 99999999999E999 does not match the data type Can any one help us how to handle this
SELECT p.party_id
,CASE
WHEN PD.DEMOG_CD ='STATUS1' THEN DEMOG_VALUE_CD
ELSE ''
END STATUS1
,MAX(STATUS1) OVER (PARTITION BY P.PARTY_ID) MAX_STATUS1
FROM DDEDWMIG_SBDW.PARTY P
INNER JOIN DDEDWMIG_SBDW.PARTY_DEMOGRAPHIC PD
ON P.PARTY_ID = PD.PARTY_ID
QUALIFY ALL(MAX_STATUS1,MAX_STATUS2,MAX_STATUS3,MAX_STATUS4) = 1
Thx Madhan M
| ||||||||||||||||||||||||||||||||||||||||||||||||
| | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
|
| ||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
| Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||