Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear All,
Please see the load script below:
[ConditionDate]:
LOAD
ERDAT
AS [F1],
DATE
(ERDAT,'dd.MMM.yyyy') AS [F2],
NUM(ERDAT) AS [F3];
SELECT
WHERE
ERDAT >= '01-01-2011';
When finished execute script I got all date data. Mean that where condition not working.
Note: I try to get data from SQL Database it ok with condition above, but I face the problem when try with SAP.
Please advice me to do this.
Thanks in advance!
In SAP the date columns wont be format of date mostly it will be like this '!11122010' so pull that in same way then take of character out make the date format in this way
DATE(LEFT([Docdate],2)&'/'&MID([Docdate],4,2)&'/'&RIGHT([Docdate],4),'DD/MM/YYYY') as Docdate.
first check ur ERDAT formate
if it is in datetime formate then ok
else
use date(makedate(left(ERDAT,4),mid(ERDAT,5,2),right(ERDAT,2)),'DD-MM-YYYY')
Hi
Thanks for your quick reply.
I have list down the field data and see in format (dd-MM-yyyy). Ex. 01-01-2010, 01-01-2011, 01-02-2011
When use where ERDAT > '01-01-2011', like example above it should be return 01-01-2011, 01-02-2011
but after finished load, I got all data (01-01-2010, 01-01-2011, 01-02-2011)
What I do wrong with this?
Please help.
Hi,
use where date(makedate(right(ERDAT,4),mid(ERDAT,4,2),left(ERDAT,2)),'DD-MM-YYYY') > '01-01-2011'
for any issue u can post me.
debug ur data and send the application with 10 records...
In SAP the date format is YYYYMMDD. You should be using the ERDAT>='YYYYMMDD'.
This one is correct for me ERDAT >'YYYYMMDD'
Many thank everybody!