Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
Good Morning.
I have two tables which i want to concatenate.
table1: table2:
week, week,
Year Year
But i need only table 1 Year.
How to achieve it.
Regards,
Joshua.
Hi,
If i use Left Join my other fields are affecting,
If i use concatenate my values are not affected only i have problems with Year.
Hi,
can you explain your requirement with some data with expected output.
Regards
Hi,
Am not sure is this what you are expecting it to be
T1:
Load * INLINE [
Week, Year, H
1, 2014,3
2, 2015,4
3, 2016,5
];
T2:
LOAD * INLINE [
Week, Year1, I
1, 2014,7
2, 2015,8
3, 2016,4
4, 2017,2
5, 2018,1
];
Concatenate(T1)
Load
Year1,
Week,
I
Resident T2
Where Exists(Year,Year1);
Drop Tables T2;
Hi joshua,
After loading table1 in the data model and without having table2 loaded already:
Concatenate (table1)
Load
week,
Year
From ...SourceOftable2 Where Exists(Year);
You would need to check if the field Year exists in tables other than table1, other wise QV will check against existing values of Year in those tables too.
Good luck
Andrew
like this
T1:
LOAD * INLINE [
Week, Year
10, 2015
20, 2016
30, 2014
];
NoConcatenate
T2:
LOAD * INLINE [
Week, Year
01, 2013
02, 2011
03, 2012
];
NoConcatenate
NewTab:
load Week,Year Resident T1
;
Concatenate
load Week Resident T2 ;
drop Tables T1,T2;
Hi all,
PFA
I want the two tables concatenated .
My calendar is Week and Year of first table in which i dont want to show year 2017.
Hi,
See this
T1:
LOAD LITM,
Market,
Week,
Year,
sales
FROM
(ooxml, embedded labels, table is Sheet1);
Concatenate(T1)
LOAD LITM,
Market,
cusWeek,
cusYear,
orders
FROM
(ooxml, embedded labels, table is Sheet2)
where exists(Year,cusYear);
Hi,
then you want to show or not the entire rows having year 2017?
what you want to do with that rows replace with any value?
try below code which remove entries for year 2017
T1:
LOAD LITM,
Market,
Week,
Year,
sales
FROM
(ooxml, embedded labels, table is Sheet1);
Concatenate(T1)
LOAD LITM,
Market,
cusWeek as WEEK,
cusYear as Year,
orders
FROM
(ooxml, embedded labels, table is Sheet2)
where cusYear<>2017;
Regards
Hi effinty2112
I loaded like this
Concatenate (table1)
Load
week,
Year
From ...SourceOftable2 Where Exists(Year);
Now i have other fields in table 2 shall i concatenate with table 1 without week ,year
or i concatenate with table 1 with week ,year
Do you want to avoid future years?
It will impact on data as you are restricting to current year.
else try in front end .
T1:
LOAD LITM,
Market,
Week,
Year,
sales
FROM
(ooxml, embedded labels, table is Sheet1);
LOAD LITM,
Market,
cusWeek as Week,
cusYear as Year,
orders
FROM
(ooxml, embedded labels, table is Sheet2) where Year(Today()) <=year(cusYear);