Logo DWBI.org Login / Sign Up
Sign Up
Have Login?
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.
Login
New Account?
Recovery
Go to Login
By continuing you indicate that you agree to Terms of Service and Privacy Policy of the site.
SAP Data Services

How to use Lookup and Join in SAP Data Services

 
Updated on Oct 01, 2020

In this tutorial, we will learn how to perform lookup and join in SAP BusinessObjects data services using the Query Transform. In the way, we will also see how to use some of the basic inbuilt functions that are provided in data services. A short video is provided with this tutorial to give you a hands-on feel in data services.

This article is part of our comprehensive data services tutorial Learning SAP Data Services - Online Tutorial, you may want to check that tutorial first if you have not already done so.

Data for illustration

For the purpose of this tutorial, we will use 3 tables namely,

  • EMP - This table contains employee information including employee number, employee name, department number, salary etc.
  • DEPT - This is the master table for Departments. It basically contains department number and department name
  • SALGRADE - This table contains salary grades based on a range of salary

How to perform Join in data Services

Given the above data sets, let us assume we want to generate below results by joining EMP and DEPT table.

EMPNO   ENAME   DNAME
7839    King    Accounting
7369    Smith   Research
.... .... ....

If we want to obtain the above set using plain SQL, we will write an SQL statement like below joining both the tables using outer join

Select e.empno, e.ename, d.dname
From Emp e Left Outer Join Dept d
On e.deptno = d.deptno

In order to perform the same join in Data Services, we will take advantage of Query Transform. Query transform is a multipurpose transform in data services that basically imitate an SQL statement and lets you do varied things including joining, aggregation, filtering etc.

We will use query transform here to establish the join between EMP and DEPT table as shown in the screenshot below

Query Transform
Query Transform

Please see the video at the bottom of this article to go-through the individual steps in Data Services

How to perform Lookup in Data Services

Theoretically a lookup is similar to a SQL function call. A function takes one or multiple values as input and returns one (or multiple) value as output. In the video below, we have demonstrated how you may use a data services lookup.

Data Services Hands-on Video

Here is a quick video that show you the steps on how to perform Join and/or lookup in BODS.

PrimeChess

PrimeChess.org

PrimeChess.org makes elite chess training accessible and affordable for everyone. For the past 6 years, we have offered free chess camps for kids in Singapore and India, and during that time, we also observed many average-rated coaches charging far too much for their services.

To change that, we assembled a team of top-rated coaches including International Masters (IM) or coaches with multiple IM or GM norms, to provide online classes starting from $50 per month (8 classes each month + 4 tournaments)

This affordability is only possible if we get more students. This is why it will be very helpful if you could please pass-on this message to others.

Exclucively For Indian Residents: 
Basic - ₹1500
Intermediate- ₹2000
Advanced - ₹2500

Top 10 Articles