Saturday 24 September 2022

Create MTA(Multi Target Application) project

 Let us create a MTA project dedicated to SDI.

Steps:

  • From web ide --> workspace -->Right click --> New --> project from template --> Choose Multi target application(MTA) -->Next --> provide <project name> --> Next --> provide the space info (dev, prod) -->Finish.
  • Right click on the MTA project, which is created in the above step -->Build.
  • Now, we don't have SRC folder --> because this project does not have a database module.
    To create Database module: Right click on the project --> New --> SAP HANA Database Module --> Provide name of the HANA module --> Finish.
  • Right click on the HANA module folder, which is created in the above step -->Build.

Friday 23 September 2022

Create HANADB remote connection

 Steps:

1. Open web IDE.

2.open HDI.

3. open catalog.

4.choose [Remote sources].

5.Right click on [Remote sources].

6.choose option --> Add Remote sources.

7.provide,


       Source Name: <name of the HANADB source-->general description>

Adapter location: <based on source system DB -->select the Adaptor>

Server: <provide server host name >

Port: <provide port number >

            3<instance number>15


Creditials:

Creditials mode: Technical user.

User Name: SYSTEM

password: <provide password>



Finally click on Create












Importing Data and Build your own models

 Steps:
1. Right Click on the workspace --> New --> Project from Template.
2. Select Multi-Target Application project --> Next.

3. Project name :   ************* --> Next.

4.Spcace: Select the correct space required --> Finish.

5. Adding SAP HANA Database Module.

   Right click on the Project name ( which is created in step 4 ) folder. -->New --> SAP HANA Database Module --> Provide <module name> -->Review --> Finish.

6. Right click on the above resultant folder --> Build.

7.Open HDI container.

     Right click on the folder created in step 5 --> Open HDI container --> HDI container specific to your project will open.

8.importing data.

 On Top of DB --> right click on it --> import catalog objects --> browse --> provide the OS path of the tar file --> change the no. Of treads if needed --> import.


_-----------------------------------------------------------------


To check whether the data imported or not. Open database and catalog --> tables.



Monday 19 September 2022

Smart data integration (SDI) & Smart data Access(SDA)

 * SDI/SDA: it is a data acquisition technique.

Installation SDI Components on the HANA server:


1. login to putty with <SID>ADM user.

2.cd /usr/sap/<sid>/home/bin/

    in here we need to run one script - to free up some space.

    if you won't run this script the DB may not able to installation SDI components - due to shortage of memory.


script name is : <SID>_gc.sh

3.Enter you system database user password:

4.Execute the below download command now:

     <SID>DownloadManager_linux.bin linuxx86_64 vm sdi.tgz


file will automatically download to the path: /usr/sap/<SID>/home/Downloads/sdi.tgz


5.cd /usr/sap/<SID>/home/Downloads/

ls

Check whether sdi.tgz file available or not


6.tar -xvf sdi.tgz

The above command is used for extracting the sdi.tgz file.

7. cd /usr/sap/<SID>/home/Downloads/HANA_EXPRESS_20/install_sdi.sh

The above cmd will install the SDI.

8.Enter HANA instance number:
9.Enter local host name: 

10.Enter system database user (SYSTEM)  password:

11.Enter name of tenant database to add smart data integration: 
12.Enter <Tenant_SID> database system user (system) password: 

13.Check the summary and press Y

14.installation of SDI component is completed - Import successful.

Restricted Column

 Restricted  columns: Are used to created a rule based access at user level.

ex: user from country USA can have USA country employee info.
      user from country IND can have IND country employee info.

Saturday 17 September 2022

Different types of Nodes

Different types of Nodes available in webide :

  • Join
  • Non Equal join
  • Union
  • Minus
  • Intersect
  • Graph
  • Projection
  • Aggregation
  • Rank
  • Table Function
  • Hierarchy Function
  • Anonymization

  Calculated Column: A column which can be built on top of original columns in the view. it can also be used independently for eg to display static values , set flags and so on.

Mapping  tab: you are settle the required set of columns and assigning them to the next node.




Wednesday 14 September 2022

To kill all the PID that related to sap

To kill all the PID that related to SAP:


 ps aux | grep -i sap* |grep adm | awk {'print $2'} | xargs kill -9

Calculated column with 2 projections and 1 join

 syntax: "companyName"+'-'+"Legal"

Steps:

1. Right click on the SRC folder -->New --> Folder--> Provide folder name --> Ok.

2.Right Click on newly created folder by the above step -->New --> Calculation view.

3. Provide name for the calculation view --> 

     Namespace - Description.

     Data category - Dimension.

     Type - Standard

Finally Click on Create

4. Create 2 projections

   insert tables in to the projections.

5. Add join node.
feed the join node with 2 projections( by drag and dropping the projections to the join).


6. Double click on the join now.


create the connection between 2 foreign 


 7. in the properties section.
   

    swap the table to right and left, if needed.

   provide the cardinality info
  join type: Left outer, right outer & Full outer.


8.in projection (flow chat)

   again select the columns in the Mapping tab.

9.Next to Mapping tab --> calculated columns tab --> click on + symbol --> 

   Provide : name, 

in the expression edition --> add expression 

"companyName"+'-'+"Legal"


10. double click on Semantics  (in the flow chart).

select the foreign key, between the tables.

11. Save all.

12. Right click on the folder below SRC -->Build.


Sunday 11 September 2022

Employee dimension calculation view

--------------------------------------------------------------------------------------------------------------------------------

 Steps:
1. Right click on the SRC folder -->New --> Folder--> Provide folder name --> Ok.

2.Right Click on newly created folder by the above step -->New --> Calculation view.

3. Provide name for the calculation view --> 

     Namespace - Description.

     Data category - Dimension.

     Type - Standard

Finally Click on Create


4. on projection --> Click + search for table and click on Finish.

5.Double click on the projection.
6. Drag and drop required columns from right to left side.
7.Click on Semantics  and select the key column.

8.Save all - option available on the left top corner.

9.Right click on the folder and Build.

10.Right click the employee table --> data preview --> Navigate to raw data tab.


Referential joins

  •  Referential joins have been introduced in HANA to improve performance.
  • Referential joins are fundamentally inner joins.

Referential joins pre- requisites:

1. Referential integrity is maintained by the central table.

2.The Cardinality is 1-N, Dimension(1) --> Transactions(N).\

 




Saturday 10 September 2022

Full Outer Join

 




--------------------------------------------------------------------------------------

/* The table 1 has 78 rows

   the Business partner table has 45 rows*/



Select * from "<Drop and Drop table 1 from HDI>" as A

Full outer join "<Drop and drop table 2 from HDI>" as B

On A."<Foreign_key name of table A>" = B. "<Foreign_key name of table B>"


----------------------------------------------------------------------------------------

Right Outer join

 







--------------------------------------------------------------------------------------
/* The table 1 has 78 rows
   the Business partner table has 45 rows*/


Select * from "<Drop and Drop table 1 from HDI>" as A                                   
Right outer join "<Drop and drop table 2 from HDI>" as B                                
On A."<Foreign_key name of table A>" = B. "<Foreign_key name of table B>"

----------------------------------------------------------------------------------------



Left Outer join



..................................................................................................................................................................

/* The table 1 has 78 rows

   the Business partner table has 45 rows*/



Select * from "<Drop and Drop table 1 from HDI>" as A

Left outer join "<Drop and drop table 2 from HDI>" as B

On A."<Foreign_key name of table A> = B. "<Foreign_key name of table B>"


..................................................................................................................................................................... 

Friday 9 September 2022

Inner join syntax

 

......................................................................................................................................................................



/* The table 1 has XX rows

   the table B has YY rows*/



Select * from "<Drop and Drop table 1 from HDI>" as A

Inner join "<Drop and drop table 2 from HDI>" as B

On A."<Foreign_key name of table A>" = B. "<Foreign_key name of table B>"






....................................................................................................................................................

HANA Modeling

 








  1. Inner join: http://basisbynaveen.blogspot.com/2022/09/inner-join-syntax.html                                 
  2. Left Outer: http://basisbynaveen.blogspot.com/2022/09/left-outer-join.html                                     
  3. Right Outer Join: http://basisbynaveen.blogspot.com/2022/09/right-outer-join.html                         
  4. Full Outer Join: http://basisbynaveen.blogspot.com/2022/09/full-outer-join.html                             
  5. Referential Joins: http://basisbynaveen.blogspot.com/2022/09/referential-joins.html                      
  6. Employee dimension calculation view :

  7. http://basisbynaveen.blogspot.com/2022/09/employee-dimension-calculation-view.html
  8. Calculated column with 2 projections and 1                                                                                          join: https://basisbynaveen.blogspot.com/2022/09/calculated-column-with-2-projections.html
  9. Different types of Nodes: https://basisbynaveen.blogspot.com/2022/09/different-types-of-nodes.html                                                                                                                                            
  10. Restricted column: http://basisbynaveen.blogspot.com/2022/09/restricted-column.html                  
  11. Smart Data Integration (SDI) & Smart Data Access (SDA) introduction and installation :   https://basisbynaveen.blogspot.com/2022/09/smart-data-integration-sdi-smart-data.html