Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
i really need help, i am trying to load data which is the Table name contains the date, since im already done with the loading, my problem is. i need to get the date from the table name itself.
Table Name is like this:
HDMF_20120210
HDMF_20120431
HDMF_20110521
I want to generate the date from Table name and connect it to my Master Calendar.
Please HELP ME...
Use this which will give you another column with the date field
LOAD
[Pag-ibig No.],
[Last Name],
[First Name],
Initial,
[Employee Contribution],
[Employer Contribution],
Birthday,
MakeDate(mid(FileName(),6,4), mid(FileName(),10,2), mid(FileName(),12,2)) as DATE
FROM
(
);
Hi,
You can use the Function Filename() while loading your table.
SAMPLE:
LOAD
Data,
FileName() as RAW_Tablename,
MakeDate(mid(FileName(),6,4), mid(FileName(),10,2), mid(FileName(),12,2)) as DATE
FROM
C:\Users\alexis.tan\Desktop\HDMF_20120210.xlsx
(ooxml, embedded labels, table is Sheet1);
Something like this.
Regards,
Alex
Use this which will give you another column with the date field
LOAD
[Pag-ibig No.],
[Last Name],
[First Name],
Initial,
[Employee Contribution],
[Employer Contribution],
Birthday,
MakeDate(mid(FileName(),6,4), mid(FileName(),10,2), mid(FileName(),12,2)) as DATE
FROM
(
);
Hi Alex,
thank you so much! I got the answer already. thanks for your help.
wow I gave the correct answer first but only helpful? nice
anyway, no problem, glad to have helped
Anyway Alex,
just curious, why does the answer you gave me has 3 parameters? thanks
did i? i maybe just an accident..
i marked your answer as a correct answer. hehe, well anyway, let me umark the helpful answer.haha!
I looked after seeing this in my inbox to tell you that you dont have to since I don't really care if you tag me as correct answer or not (I even said im glad to have helped). But unmarking me EVEN just as helpful o.o" THANK YOU? no points for me after I gave the answer I guess.
sanuela_jro wrote:
i marked your answer as a correct answer. hehe, well anyway, let me umark the helpful answer.haha!
GoodLuck