Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

compare the output of two expressions and get the common values

hi,

I had a pivot table with two dimensions and two expressions.Now i need to compare the output of two expressions and get  the common values in them. can any one please help me how to do this?

LOAD (@1/86400 + 25569)  as [time stamp],

   
@2 as [network id],

   
@3 as msisdn

FROM



(
txt, codepage is 1252, no labels, delimiter is ',', msq);

LOAD @1 as [network id],

    
@2 as lat,

    
@3 as long

FROM



(
txt, codepage is 1252, no labels, delimiter is spaces, msq);

LOAD (@1/86400 + 25569)  as [time stamp1],

   
@2 as [network id1],

   
@3 as msisdn1

FROM



(
txt, codepage is 1252, no labels, delimiter is ',', msq);



LoAD @1 as [network id1],

    
@2 as lat,

    
@3 as long

FROM



(
txt, codepage is 1252, no labels, delimiter is spaces, msq);

My pivot table expressions and dimensions are something like below

latlongFirstSortedValue(msisdn,[time
  stamp])
FirstSortedValue(msisdn1,[time
  stamp1])
1.2924103.8152525-00-10009525-00-10013
1.2963103.8569525-00-10018525-00-10012
1.2975103.8521525-00-10004525-00-10017
1.3019103.84525-00-10004525-00-10002
1.307103.8292525-00-10020525-00-10010
1.3098103.8769525-00-10001525-00-10001
1.3122103.7501525-00-10016525-00-10015
1.3129103.9247525-00-10011525-00-10013
1.3218103.904525-00-10017525-00-10019
1.3224103.6572525-00-10012525-00-10006
1.3282103.8862525-00-10020525-00-10007
1.3295103.9668525-00-10016525-00-10011
1.3308103.952525-00-10009525-00-10011
1.3335103.9426525-00-10012525-00-10016
1.3357103.8528525-00-10015525-00-10008
1.3359103.9718525-00-10018525-00-10012
1.3373103.8504525-00-10013525-00-10004
1.3412103.9848525-00-10002525-00-10003
1.3514103.9677525-00-10009525-00-10017
1.3526103.7237525-00-10009525-00-10014
1.3625103.9562525-00-10017525-00-10019
1.3669103.862525-00-10008525-00-10012
1.3828103.9365525-00-10014525-00-10016
1.4217103.8375525-00-10004525-00-10008
1.4265103.8343525-00-10019525-00-10001
1.4275103.837525-00-10012525-00-10016
1.431103.8376525-00-10007525-00-10019
1.443103.7879525-00-10005525-00-10010
1.4484103.8525-00-10012525-00-10003
1.4485103.806525-00-10006525-00-10009

        Now i want to get the get the common values in both the expressions. please help me how to do this




http://192.168.127.79/PEARL.pac

3 Replies
tresesco
MVP
MVP

Do you want a third expression which tells if the first and second expressions match? If so, try third expression like:

If( FirstExpressionLabel=SecondExpressionLabel, FirstExpressionLabel)

// change the label accordingly.

Not applicable
Author

Hi,

You can use the * .It means intersection which take the common values between two expressions

Expression3=Expression1*Expression2

Hope it helps you

Not applicable
Author

hi,

i need to get the common values only. something as below. no need of getting the firstsorted value

lat     long     msisdn     msidn1     commonvalues(msisdn ).

I need to display this in a pivot table.