Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi i understand the concept of lookup function but i dont know how to say that concept in terms of technically pls help any body?
See this document: Joins and Lookups
Hey Manoj,
Check out the attached file from Jagan Mohan. This is a very simple example of the basic concept behind lookup function. Once you go through it you will be more clear.
Lookup('Output Field','SearchField',SearchValue,'TableName')
Hope it helps
Thanks
AJ
Manoj Kumar:
You can also read any document regarding APPLY MAP and Mapping Tables.
This function is very similar to lookup and easier to undersand (at least, for begginers).
CB.
SaleLastYear:
Load * Inline
[
Customer_ID, Sales2012
A, 500
B, 600
C, 700
D, 400
E, 1000
F, 800
];
Sales:
Load *,
Lookup('Sales2012','Customer_ID', ID,'SaleLastYear') as LYSale ----------(here sales2012 ,customer_id, and saleslastyear from same table
Inline but id is from second table is it mandatory)pls exlain
[
ID, Month2013, Sales
A, Jan, 100
B, Jan, 200
C, Jan, 300
D, Feb, 150
E, Mar, 200
F, Apr, 100
A, May, 140
D, May, 80
E, May, 100
F, Jun, 150
];
Lookup('Sales2012','Customer_ID', ID,'SaleLastYear') as LYSale
Here we have two tables..
SaleLastYear : having two fields Customer_ID, Sales2012
Sales : having three fields ID, Month2013, Sales
Our aim is to get Last Year Sales (i.e. Sales2012) for each Customer so that we can compare it to current year.
As Ajay has mentinoned...
Lookup('Output Field','SearchField',SearchValue,'TableName')
Output Field = Sales2012, means the result field we need from the other table
SearchField = Customer_ID, means the matching field from other table
SearchValue = ID, means the field of current table in which we are using Lookup and which is comparable to SearchField of other table.
TableName = SaleLastYear, means Name of table from which the we need output.
Hope this will make you clear about LOOKUP function.
Excellent
Can you close the thread by selecting CORRECT answer?