Posts

Showing posts with the label SQL Join

Using BAPI upload excel file for t-code AS02 in SAP

Using BAPI " BAPI_FIXEDASSET_CHANGE " create a zprogram to upload excel file for mass change fixed asset in SAP. REPORT  ZAS02_ASSET_CHANGE_UPLOAD . TYPE-POOLS :  truxs . " Structure for Excel data TYPES :  BEGIN  OF  ty_excel ,          anln1  TYPE  anln1 ,          bukrs  TYPE  bukrs ,          kostl  TYPE  kostl ,          werks  TYPE  werks ,          prctr  TYPE  prctr ,         END  OF  ty_excel . DATA :  lt_excel     TYPE  TABLE  OF  ty_excel ,       ls_excel     TYPE  ty_excel ,     ...

SQL Join

Image
  SQL Joining: Joins in SQL are used to query (retrieve) data from 2 or more related tables. In general tables are related to each other using foreign key constraints. In SQL there are different types of JOINS: 1. CROSS JOIN 2. INNER JOIN 3. OUTER JOIN Outer Joins are again divided into 3 types: 1. Left Join or Left Outer Join 2. Right Join or Right Outer Join 3. Full Join or Full Outer Join General Formula for Joins SELECT       ColumnList FROM            LeftTableName JOIN_TYPE   RightTableName ON                  JoinCondition CROSS JOIN: CROSS JOIN, produces the Cartesian product of the 2 tables involved in the join. Cross Join shouldn't have ON clause. CROSS JOIN Query: SELECT ColumnName1, ColumnName2, ColumnName3,ColumnName4 FROM tableName CROSS JOIN tableName2(joining...