Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have this list one in check.xlsx.
After i do group by on method name and show count(Parameters)
I get a list of Method Name and Count of Parameters like example
Method Name | Parameters |
---|---|
A | 2 |
B | 3 |
C | 3 |
D | 5 |
Now i want out put as
Source Method | Destination Method | SourceCountParameters | Destinationcountparamters |
---|---|---|---|
A | B | 2 | 3 |
A | C | 2 | 3 |
A | D | 2 | 5 |
B | A | 3 | 2 |
B | C | 3 | 3 |
B | D | 3 | 5 |
This means i am comparing each method with all other method names with their paramters.
Let me know how cani achieve this.
Hi,
Try this script
Temp:
LOAD * INLINE [
Method, Parameter
A, a
A, b
A, c
A, f
B, b
B, c
B, d
B, f
B, e
C, a
C, b
C, x
C, z
C, r
C, t
D, w
D, e
E, a
E, b
E, c
E, f
F, a
F, h
F, g
F, d
F, f
];
Data:
LOAD
Method AS SourceMethod,
Count(Parameter) AS SourceCount
Resident Temp
Group by Method;
LEFT JOIN(Data)
LOAD
SourceMethod AS DestinationMethod,
SourceCount AS DestinationCount
Resident Data;
FinalData:
NoConcatenate
LOAD
*
Resident Data
WHERE SourceMethod <> DestinationMethod;
DROP TABLEs Temp, Data;
Regards,
Jagan.
Hi,
Try this script
Temp:
LOAD * INLINE [
Method, Parameter
A, a
A, b
A, c
A, f
B, b
B, c
B, d
B, f
B, e
C, a
C, b
C, x
C, z
C, r
C, t
D, w
D, e
E, a
E, b
E, c
E, f
F, a
F, h
F, g
F, d
F, f
];
Data:
LOAD
Method AS SourceMethod,
Count(Parameter) AS SourceCount
Resident Temp
Group by Method;
LEFT JOIN(Data)
LOAD
SourceMethod AS DestinationMethod,
SourceCount AS DestinationCount
Resident Data;
FinalData:
NoConcatenate
LOAD
*
Resident Data
WHERE SourceMethod <> DestinationMethod;
DROP TABLEs Temp, Data;
Regards,
Jagan.
Hi jagan its working fine
Can you please explain a little?
And also need one more help further with this as i see soem problem in output.
okay i understood
But can you tell me if i want to compare the values one by one in the same column ....what should i do?
suppose there are 1000 rows or more than that
HI,
Can you explain what do you mean by compare the values one by one in same column? Can you explain with an example?
Regards,
Jagan.
Yeah Jagan,
http://community.qlik.com/message/646457#646457
Aim is to remove duplicate methods which causes performance issues.
So there are some methods having same number of parameters and some are subset.so i want to know which all are duplicates and which all are subset or no match