I'm trying to extract data in specific time period from SAP "TCURR" table via Connector regarding the field "GDATU".
Since the data format of TCURR-GDATU is like '79829298', which means 2017/07/01, I'm wondering if I could convert the format with where clause in sql script.
I've tried cast and convert function as below, but it showed that there's no such functions like cast() and convert().
Thanks in advanced.
***** Script *****
SET vStartDate = '20170601';
SET vEndDate = '20170630';
Let vStart_Convert = Num#('99999999','########')- Num#($(vStartDate),'########');
Let vEnd_Convert = Num#('99999999','########')-Num#($(vEndDate),'########');
[TCURR]:
LOAD MANDT,
KURST,
FCURR,
TCURR,
GDATU,
UKURS,
FFACT,
TFACT,
Date(Date#(Evaluate('99999999')-NUM#(GDATU),'YYYYMMDD')) as GDATE;
Select
MANDT,
KURST,
FCURR,
TCURR,
GDATU,
UKURS,
FFACT,
TFACT
From TCURR WHERE (Convert(INT,GDATU)>=$(vStart_Convert) and Convert(INT,GDATU)<=$(vEnd_Convert));