Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm doing a simple script to order the Time Dimension table...
After the reload the table DimTimeMonthly is not loaded, without the last code line "Drop Table DimTimeMonthly_Temp;",
the table DimTimeMonthly is loaded with duplicated lines?!
Provably it's a very simple code error...
Thanks in advance...
MonthNr:
Mapping
LOAD * INLINE [
Month, MonthID
Jan, 1
Feb, 2
Mar, 3
Apr, 4
May, 5
Jun, 6
Jul, 7
Aug, 8
Sep, 9
Oct, 10
Nov, 11
Dec, 12
];
DimTimeMonthly_Temp:
LOAD MonthID,
MonthName,
Mid(MonthName,1,3) as Month,
YearID,
YearName as Year,
RelativeMonthID,
MATID,
MATOrderID,
MAT,
,ApplyMap('MonthNr',Mid(MonthName,1,3), 'NA') as MonthNr
FROM
..\DataSources\$(vQVDsBeg_Name)DimTimeMonthly.qvd
(qvd)
where RelativeMonthID>0;
DimTimeMonthly:
LOAD *
Resident DimTimeMonthly_Temp
order by MonthNr;
Drop Table DimTimeMonthly_Temp;
Here is an example:
DimTimeMonthly:
NoConcatenate
LOAD *
Resident DimTimeMonthly_Temp
order by MonthNr;
If you don't use NoConcatenate, then QlikView will just ignore the statement, because the 2 tables have identical columns (identical column names and identical number of columns).
Correction:
Hi,
I'm doing a simple script to order the Time Dimension table...
After the reload the table DimTimeMonthly is not loaded, without the last code line "Drop Table DimTimeMonthly_Temp;",
the table DimTimeMonthly_Temp is loaded with duplicated lines?!
Provably it's a very simple code error...
Thanks in advance...
MonthNr:
Mapping
LOAD * INLINE [
Month, MonthID
Jan, 1
Feb, 2
Mar, 3
Apr, 4
May, 5
Jun, 6
Jul, 7
Aug, 8
Sep, 9
Oct, 10
Nov, 11
Dec, 12
];
DimTimeMonthly_Temp:
LOAD MonthID,
MonthName,
Mid(MonthName,1,3) as Month,
YearID,
YearName as Year,
RelativeMonthID,
MATID,
MATOrderID,
MAT,
,ApplyMap('MonthNr',Mid(MonthName,1,3), 'NA') as MonthNr
FROM
..\DataSources\$(vQVDsBeg_Name)DimTimeMonthly.qvd
(qvd)
where RelativeMonthID>0;
DimTimeMonthly:
LOAD *
Resident DimTimeMonthly_Temp
order by MonthNr;
Drop Table DimTimeMonthly_Temp;
Could you share your qvw?
Hello, you have to use "NoConcatenate" because your temp table and your "permanent" table have the exact same columns.
Here is an example:
DimTimeMonthly:
NoConcatenate
LOAD *
Resident DimTimeMonthly_Temp
order by MonthNr;
If you don't use NoConcatenate, then QlikView will just ignore the statement, because the 2 tables have identical columns (identical column names and identical number of columns).
Thanks...