Sei sulla pagina 1di 58

What is Sap HANA?

SAP HANA is the latest ERP Solution from SAP, which is a combination of
Hardware and Software. HANA has unprecedented adoption by the SAP customers.

SAP HANA is latest, in-memory database, and platform which can be deployed on-
premises or cloud. SAP HANA is a combination of hardware and software, which
integrates different components like SAP HANA Database, SAP SLT (System
Landscape Transformation) Replication server, SAP HANA Direct Extractor
connection and Sybase replication technology

SAP HANA Database & Platform


1. SAP HANA Database – SAP HANA Database is a hybrid in–memory
database. SAP HANA Database is the heart of SAP in-memory technology. In
SAP HANA, Database table are of two types –

 Row Store
 Column Store

2. SAP HANA Platform – SAP HANA Platform is a development platform with an


in-memory data store which allows the customers to analyze a large volume
of data in real time. SAP HANA Platform works as a development platform,
which provides infrastructure and tools for building a high-performance
application based on SAP HANA Extended Application Services (SAP HANA
XS).

SAP HANA Edition


There are different types of SAP HANA edition, some of them as below-

 SAP HANA Platform Edition – It provides Core database technology. It


Integrate SAP component like SAP HANA database, SAP HANA Studio and
SAP HANA clients. It is for customers who want to use ETL-based replication
and already have a license for SAP Business Objects Data Services.
 SAP HANA Enterprise Edition – It contains data provisioning (SLT, BODS,
DXC) component including core database technology. It is for customers who
want to use either trigger-based replication or ETL-based replication and do
not have all of the necessary license for SAP Business Objects Data
Services.
 SAP HANA Extended Edition – It contains data provisioning (Sybase)
features more than Platform and Enterprises edition. It is for customers who
want to use the full potential of all available replication scenarios including
log-based replication.

The following diagram shows difference between all editions –

Why to choose SAP HANA?


SAP HANA is a next-generation in-memory business platform. It accelerates
analytics and application on a single and in-memory platform.

Mentioned below are the few reasons why to choose SAP HANA –

 Real Time – SAP HANA Provides Real-Time Data Provisioning and Realtime
Reporting.
 Speed – SAP HANA provide high speeds processing on massive data due to
In-Memory Technology.
 Any Data/Source- SAP HANA can access various data source including
Structured and Un-Structured data from SAP or Non-SAP data source.
 Cloud- SAP HANA database and application can be deployed to the Cloud
environment.
 Simplicity – SAP HANA reduce efforts behind ETL process, Data
Aggregation, Indexing, and Mapping.
 Cost – SAP claims that SAP HANA Software can reduce Total IT cost of a
company.
 Choice Option – SAP HANA is supported by different hardware vendor and
Software provider, so based on the requirement, the user can choose the best
option.
SAP HANA In-Memory Strategy
SAP HANA has many processes running on the SUSE Linux Server. SUSE Linux
server manages the reservation of memory to all process.

When SAP HANA starts up, Linux OS reserves memory for the program code,
program stack, and static data. OS can dynamically reserve additional data memory
upon request from the SAP HANA Server.

SAP HANA create a memory pool for managing and tracking the consumption of
memory. The memory pool is used to store all the in-memory data and system
tables, thread stack, temporary computations and all other data structure required
for managing the database.

When more memory is required for table growth or temporary computations, the
SAP HANA memorymanager obtains this from the pool.
For an overview, check out the Memory Overview feature of the SAP HANA studio.
To access it, right-click on a System ->Configuration and Monitoring -> Open
Memory Overview in the context menu, as follows:

SAP HANA Advantages


Below are advantages of SAP HANA -

 By In-Memory Technology user can explore and analyze all transactional and
analytic data in real time from virtually any data source.
 Data can be aggregated from many sources.
 Real-time replication services can be used to access and replicate data from
SAP ERP.
 SQL and MDX interface from third party support.
 It provides information modeling and design environment.

SAP HANA Compare to BWA (Business Warehouse


Accelerator)
 SAP BW Accelerator: It is an in-memory accelerator for BW. BWA is focused
on improving the query performance of SAP NetWeaver BW. BWA is
specifically designed to accelerate BW queries reducing the data acquisition
time by persisting copies of the infocube.
 SAP HANA: SAP HANA is in-memory database and platform for high-
performance analytic reports and application. In SAP HANA data can be
loaded from SAP and non-SAP Source System through SLT, BODS, DXC,
and Sybase and can be viewed using SAP BO/BI, Crystal Reports, and Excel,
etc.

Currently, SAP HANA also work as in-Memory database for SAP BW, so in this way
SAP HANA able to improve the overall performance of SAP Net weaver BW.

Summary:
 SAP HANA is an in-memory database and application, which runs on SAP
authenticated hardware and Software.
 SAP HANA have three version – platform, enterprises and extended.
 SAP HANA can load data from SAP and Non-SAP data source through SLT,
BODS, DXC, and Sybase.
 SAP HANA provide real-time provisioning and reporting.
 SAP HANA provide high-performance real-time analytic reporting.
 SAP HANA reduces Total IT cost.

SAP HANA Architecture, LandScape, Sizing: Complete Tutorial


SAP HANA Database is Main-Memory centric data management platform. SAP
HANA Database runs on SUSE Linux Enterprises Server and builds on C++
Language.

SAP HANA Database can be distributed to multiple machines.

SAP HANA Advantages are as mentioned below -

 SAP HANA is useful as it's very


fast due to all data loaded in-
Memory and no need to load data
from disk.
 SAP HANA can be used for the
purpose of OLAP (On-line analytic)
and OLTP (On-Line Transaction)
on a single database.

SAP HANA Database consists of a set of in-memory processing engines.


Calculation engine is main in-memory Processing engines in SAP HANA. It works
with other processing engine like Relational database Engine(Row and Column
engine), OLAP Engine, etc.

Relational database table resides in column or row store.

There are two storage types for SAP HANA table.

1. Row type storage (For Row Table).


2. Column type storage (For Column Table).

Text data and Graph data resides in Text Engine and Graph Engine respectively.
There are some more engines in SAP HANA Database. The data is allowed to store
in these engines as long as enough space is available.
In this tutorial, you will learn-

 SAP HANA Architecture


 SAP HANA Landscape
 SAP HANA Sizing

SAP HANA Architecture


Data is compressed by different compression techniques (e.g. dictionary encoding,
run length encoding, sparse encoding, cluster encoding, indirect encoding) in SAP
HANA Column store.

When main memory limit is reached in SAP HANA, the whole database objects
(table, view,etc.) that are not used will be unloaded from the main memory and
saved into the disk.

These objects names are defined by application semantic and reloaded into main
memory from the disk when required again. Under normal circumstances SAP
HANA database manages unloading and loading of data automatically.

However, the user can load and unload data from individual table manually by
selecting a table in SAP HANA studio in respective Schema- by right-clicking and
selecting the option "Unload/Load".

SAP HANA Server consists of

1. Index Server
2. Preprocessor Server
3. Name Server
4. Statistics Server
5. XS Engine
1. SAP HANA Index Server

SAP HANA Database Main server are index server. Detail of each server is
as below-

 It's the main SAP HANA database component


 It contains actual data stores and the engine for processing the data.
 Index Server processes incoming SQL or MDX statement.

Below is the architecture of Index Server.


SAP HANA Index Server overview

 Session and Transaction Manager: Session Component manage sessions and connections for SAP
HANA database. Transaction Manager coordinates and control transactions.

 SQL and MDX Processor: SQL Processor component queries data and send to them in query
processing engine i.e. SQL/SQL Script / R / Calc Engine. MDX Processor queries and manipulates
Multidimensional data (e,g. Analytic View in SAP HANA).

 SQL / SQL Script / R / Calc Engine: This Component executes SQL / SQL script and calculation data
convert in calculation model.

 Repository: Repository maintain the versioning of SAP HANA metadata object e.g.(Attribute view,
Analytic View, Stored procedure).

 Persistence layer: This layer uses in-built feature "Disaster Recovery" of SAP HANA database. Backup
is saved in it as save points in the data volume.

2. Preprocessor Server

This server is used in Text Analysis and extracts data from a text when the search
function is used.

3. Name Server

This Server contains all information about the system landscape. In distributed
server, the name server contains information about each running component and
location of data on the server. This server contains information about the server on
which data exists.
4. Statistic Server

Statistic server is responsible for collecting the data related to status, resource
allocation / consumption and performance of SAP HANA system.

5. XS Server

XS Server contains XS Engine. It allows external application and developers to use


SAP HANA database via the XS Engine client. The external client application can
use HTTP to transmit data via XS engine for HTTP server.

SAP HANA Landscape


"HANA" mean High Performance Analytic Appliance is a combination of
hardware and software platform.

 Due to change in computer architecture, the more powerful computer is


available in terms of CPU, RAM, and Hard Disk.
 SAP HANA is the solution for performance bottleneck, in which all data is
stored in Main Memory and no need to frequently transfer data from disk I/O
to main memory.

Below are SAP HANA Innovation in the field of Hardware/Software.

There are two types of Relational data stores in SAP HANA: Row Store and Column
Store.

Row Store

 It is same as Traditional database e.g. (Oracle, SQL Server). The only


difference is that all data is stored in row storage area in memory of SAP
HANA, unlike a traditional database, where data is stored in Hard Drive.

Column Store

 Column store is the part of the SAP HANA database and manages data in
columnar way in SAP HANA memory. Column tables are stored in Column
store area. The Column store provides good performance for write operations
and at the same time optimizes the read operation.

Read and write operation performance optimized with below two data structure.

Main Storage

Main Storage contains the main part of data. In Main Storage, suitable data
compression Method (Dictionary Encoding, Cluster Encoding, Sparse Encoding,
Run Length encoding, etc.) is applied to compress data with the purpose to save
memory and speed up searches.

 In main storage write operations on compressed data will be costly, so write


operation do not directly modify compressed data in main storage. Instead, all
changes are written in a separate area in column storage known as "Delta
Storage."
 Delta storage is optimized for a write operation and uses normal compression.
The write operations are not allowed on main storage but allowed on delta
storage. Read operations are allowed on both storages.

We can manually load data in Main memory by option "Load into Memory" and
Unload data from Main memory by "Unload from Memory" option as shown below.
Delta Storage

Delta storage is used for a write operation and uses basic compression. All
uncommitted modification in Column table data stored in delta storage.

When we want to move these changes into Main Storage, then use "delta merge
operation" from SAP HANA studio as below –

 The purpose of delta merge operation is to move changes, which is collected


in delta storage to main storage.
 After performing Delta Merge operation on sap column table, the content of
main storage is saved to disk and compression recalculated.

Process of moving Data from Delta to Main Storage during delta merge
There is a buffer store (L1-Delta) which is row storage. So in SAP HANA, column
table acts like row store due to L1-delta.

1. The user runs update / insert query on the table (Physical Operator is SQL
statements.).
2. Data first go to L1. When L1 moves data further (L1- Uncommitted data)
3. Then data goes to L2-delta buffer, which is column oriented. (L2- Committed
data)
4. When L2-delta process is complete, data goes to Main storage.
So, Column storage is both Write-optimized and Read-optimized due to L1-Delta
and main storage respectively. L1-Delta contains all uncommitted data. Committed
data moves to Main Store through L2-Delta. From main store data goes to the
persistence layer (The arrow indicating here is a physical operator that send SQL
Statement in Column Store). After Processing SQL Statement in Column store, data
goes to the persistence layer.

E.g. below is row-based table-

Table data is stored on disk in linear format, so below is format how data is stored
on disk for row and column table -

In SAP HANA memory, this table is stored in Row Store on disk as format –

Memory address

And in Column, data is stored on disk as –

Memory address

Data is stored column-wise in the linear format on the disk. Data can be compressed
by compress technique.

So, Column store has an advantage of memory saving.

SAP HANA Sizing


Sizing is a term which is used to determine hardware requirement for SAP HANA
system, such as RAM, Hard Disk and CPU, etc.

The main important sizing component is the Memory, and the second important
sizing component is CPU. The third main component is a disk, but sizing is
completely dependent on Memory and CPU.

In SAP HANA implementation, one of the critical tasks is to determine the right size
of a server according to business requirement.
SAP HANA DB differ in sizing with normal DBMS in terms of –

 Main Memory Requirement for SAP HANA ( Memory sizing is determined by


Metadata and Transaction data in SAP HANA)
 CPU Requirement for SAP HANA (Forecast CPU is Estimated not accurate).
 Disk Space Requirement for SAP HANA ( Is calculated for data persistence
and for logging data)

The Application server CPU and application server memory remain unchanged.

For sizing calculation SAP has provided various guidelines and method to calculate
correct size.

We can use below method-

1. Sizing using ABAP report.


2. Sizing using DB Script.
3. Sizing using Quicksizer Tool.

By using Quicksizer tool, Requirement will be displayed in below format-

How to Download & Install SAP HANA Studio


What is SAP HANA Studio?
SAP HANA Studio is an Eclipse based, integrated development environment (IDE)
for development and administration of SAP HANA Database in the form of GUI tool.
SAP HANA Studio runs on client/developer machine and connects to SAP HANA
Server. SAP HANA Studio can access local or remote SAP HANA Database.

By using SAP HANA Studio we can –

 Enables user to manage the SAP


HANA Database.
 Create and manage user
authorizations.
 Create New or modify existing
models of data.

In this tutorial, you will learn-

 Pre-Requisite for SAP HANA Studio


 Supported Platform
 Download & Install SAP HANA Studio
 Add System in SAP HANA Studio
 Work With SAP HANA Studio

Pre-Requisite for SAP HANA Studio


Supported Platform
SAP HANA Studio runs on below platform –

Microsoft Windows x32 and x64 versions-

 Window XP
 Window Vista
 Window 7
 Window 8

 SUSE Linux Enterprises Server: x86 64 Bit version, Red Hat Enterprises
Linux (6.5).
 Mac OS 10.9 or Higher.

System Requirement

 JAVA JVM – During Installation and updating of SAP HANA Studio, a JVM is
installed or updated.
 SAP HANA Client – It is software, by which you will be able to connect any
other database, application.
o SAP HANA Client can be installed on Unix / Linux and Microsoft
Windows and also on SAP HANA Server host during server installation.
SAP HANA Client installed separately from SAP HANA studio.

Download & Install SAP HANA Studio


Installation Path
The default installation on system path according to OS and their version is as below

 Microsoft Window (32 & 64 bit)- C:\Program files \sap\hdbstudio.


 Linux x86, 64 bit - /user / sap / hdbstudio.
 Mac OS , 64 bit - /Applications / sap / hdbstudio.app

Software Download
You can download SAP HANA Studio and SAP HANA Client from here

Select File To Download according to your OS –

Installation on Microsoft Window


Install SAP HANA Studio in the default directory with administration privileges or in
user home folder without administration privileges.

Click on hdbsetup.exe for installing SAP HANA studio.

A SAP HANA Lifecycle Management Screen appears.


Default installation folder is C:/Program Files / SAP / hdbstudio.

Step 1) Define Studio Properties


1. Select install new SAP HANA Studio.
2. Click on Button.

Select Features screen appear as below –

Step 2) Select features


1. Select Features screen are used to select features.
2. Select Feature as below -

 SAP HANA Studio Administration – Toolset for various administration task,


Excluding Transport.
 SAP HANA Studio Application Development – Toolset for developing SAP
HANA native Applications (XS and UI5 Tools excluding SAPUI5).
 SAP HANA Studio Database Development – Toolset for content
development.

3. Click button.

Step 3) Review and Confirm


1. Review & Conform Screen appears.
2. Summary of SAP HANA Studio Installation display.
3. Click on Button.

Step 4 & 5) Install Software and Finish.

1. Installation Progress screen appear and after it goes to finish page.


2. A Message "You have successfully installed the SAP HANA Studio".
3. Click on button.

Run SAP HANA Studio


Now, go to Default installation folder is "C:/Program Files / SAP / hdbstudio".

There is hdbstudio.exe file, by right clicking on it, you can create a shortcut on the
desktop.

When you click "hdbstudio.exe" file, it will open Workspace Launcher screen
displayed below.
1. Workspace is selected by default. We can change Workspace location by
Browse option. Workspace is used to store studio configuration settings and
development artifacts.
2. Select "Use this as the default and do not ask again" option to prevent popup
this screen every time for workspace selection when we open SAP HANA
Studio.
3. Click Button.
SAP HANA Studio Welcome screen appear -

In the Welcome screen different perspective is displayed, Detail of each perspective


is as below –

1. Administration Console Perspective


This screen is used to configure, administration and monitoring the SAP
HANA Database. Several View and editor are available in SAP HANA
Administration Console.

System View Toolbar is used for Administration; it looks like as below –

Below is a Table showing System-level editors and views available in SAP


HANA Administration Console.

View/ Editors Detail Path image

Systems The System view Window->


provides Show View ->
hierarchical view System
of all the SAP
HANA System
managed in SAP
HANA Studio with
their contents
(catalog, content,
etc.)

System System Monitor is Button


Monitor an editor which on System
provides an View Toolbar.
overview of all SAP
HANA Database at
one screenshot.
We can see the
detail of the
individual system
in System Monitor
by drill down.
Administration This is used for 1. From The
performing System
administration and Toolbar. 2. By
monitoring task. double click on
System.

Administration This editor is used 1. From click


Diagnosis in case of Administration
Mode emergency to tool list icon.
perform monitor 2.Ctrl+Shift + O
and operation on
the system in
which either No
SQL connection
available or
the SQL connection
overload.

Backup Used in performing Expand the


Backup and system and
Administration. choose
backup.

Security This editor is used Security option


for managing from Security
below topic- views of the
1.Password Policy system.
2.Data Volume
Encryption

SQL Console Used for Entering, From the


Executing and System Toolbar
analyzing SQL Choose SQL
statement in SQL
Console.

2. Modeler Perspective
This perspective is used to create modeling objects, database object
management in SAP HANA System. This perspective used by modelers for
the following activity –

 Create / Modify Tables, Functions, Indexes, View, Sequences, Synonym,


Trigger, Views.
 Create Modelling object like Attribute View, Analytic View, Calculation View,
Analytic Privileges, Procedures and Decision Table.
 Data Provisioning to SAP HANA database from SAP / NonSAP Source
through SLT, BODS, DXC.

3. Development Perspective
This Perspective is used to develop an application on HANA for the web
environment. In this Perspective programming language is used – Java
Script, J Query, ODATA, etc.

4. Lifecycle Management Perspective


This screen is used to Install and Update software regarding SAP HANA
Database and SAP HANA Studio. Lifecycle management is also used to
transport an object from one HANA system to another HANA System.

Add System in SAP HANA Studio


To work with SAP HANA Database user needs to be connected with SAP HANA
database from SAP HANA Studio. So we build a connection to SAP HANA
DATABASE as below –

Step 1) Click on "Add System" icon from System Toolbar as below-

Step 2) Provide the following detail as below –

1. Host Name – Enter SAP HANA database here.


2. Instance Number – Two Digit Instance number.
3. Description – Description of the system for better understanding
4. Click on button.
A connection properties screen appears in which we need to enter SAP HANA
Database User and Password.
1. Enter Username and Password for SAP HANA Database for access it from
SAP HANA Studio.
2. Click button.

If there is no error, then the connection is successful, and System name is


added in SAP HANA Studio under System Node.

Work With SAP HANA Studio


To login in SAP HANA Database through SAP HANA Studio, follow below steps-
1. Click on Added System. Here" DB (HANAUSER)".
2. A popup screen for User Name/ password. Enter User Name and Password
for HANA Database.
3. Click on Ok button.

After Login to SAP HANA Studio, We get below screen for selected HANA System.

In Hana Studio under HANA System following sub-nodes exits-

 Catalog
SAP HANA Studio Catalog node represent SAP HANA data dictionary, in which
Database object (Table, View, Procedure, Index, Trigger, Synonyms, etc.) stores in
Schema Folder. When the user is created in SAP HANA, Schema of the same name
will be created in SAP HANA Database by default. This is a default schema of user
when a user creates any database object. Schema is used to group database
object.

Schema defines a container that hold database objects such as Table, Views,
Trigger, Procedure, Sequence, Function, Indexes, Synonyms, etc.
Schema can be created in SQL Editor by below SQL-

CREATE SCHEMA "SCHEMA_NAME" OWNED BY "USERNAME".

Here "SCHEMA_NAME" AND "USERNAME" Should be changed according to


Requirement. After Refresh Catalog Node Newly Created Schema will be displayed.

I have created Schema "DHK_SCHEMA" by it in-front SQL.

All Database Object are stored in respective folder of Schema as below –

 Provisioning
Provisioning is used for selecting source Meta data and importing metadata and
data into SAP HANA.

There are two categories of provisioning, they are -

1. SAP HANA In-Built Tool (Flat file, Smart Data Access, Smart Data Streaming,
etc.)
2. External Tools (SLT, BODS, DXC, etc.)
In SAP HANA Studio Provisioning node, SAP uses a new feature called, "Smart
Data Access" which is Built in Tool.

Smart Data Access combines data from heterogeneous data sources like Hadoop,
Teradata, Oracle, and Sybase.

Data from different sources will store in SAP HANA database as "Virtual Table". The
restriction with virtual tables is, it can be only used to build calculation views in SAP
HANA.

 Content
Content Node is Design Time Repository, which hold all information of data models
in the package. All information view e.g.(Attribute View, Analytic View, Calculation
View, etc.) will be created in Package under Content Node.

The package is used for grouping related information object in a structured way. The
package can be created by clicking right click on Content Node ->New->Package.

 Security
Security Node in SAP HANA Studio contain 3 Sub-node, they are –

1. Security – Used for Create User Audit Policy, Password Policy, etc.
2. Users – Used for create/Modify/Delete user. Role and Privileges will also
grant to user from this screen.
3. Roles – Used for Create/Modify/ delete Roles. Privileges are added/deleted
from here to Role.

SAP HANA SQL: Learn in 10 Minutes


Most RDBMS database uses SQL as database language, the reason of being
popular is – it is powerful, vendor independent and standardized. SAP HANA also
supports SQL.

In SAP HANA, SQL is the main database language.


What is SAP HANA SQL?
SQL Stands for Structured Query Language. It is a Standard Language for
communicating with Relational database like Oracle, MySQL etc. SQL is used to
store, retrieve and modify the data in the database.

By using SQL in SAP HANA, we can perform following job-

 Schema definition and use (CREATE SCHEMA).


 DML Statement (SELECT, UPDATE, INSERT).
 DDL Statement ( CREATE , ALTER , DROP )
 DCL Statement ( GRANT ,REVOKE)
 System Management
 Session Management
 Transaction Management

Comment in SQL

We can add a comment to improve the readability and maintainability of SQL


Statements. Comment can be put on SQL in two ways-

 Single Line Comment - Double Hyphens "—". This is one line comment.
 Multiple Line Comment – "/* */ ".

All Commented text is ignored by SQL Parser.

SAP HANA Data Type & Identifiers


In this tutorial, we will learn,

1) SAP HANA Data Type

2) SAP HANA Identifiers

SAP HANA Data Type


In SAP HANA Database, SQL Data Type is as below –

Classification Sub- SQL Data Type Column Store Default Format


Classification Type
Date Times Date DATE CS_DAYDATE 'YYYY-MM-DD'
Types

Time TIME CS_SECONDTIME 'HH34:MI:SS'

Second Date SECONDDATE CS_LONGDATE 'YYYY-MM-DD HH34:MI:SS'

Time Stamp TIMESTAMP CS_SECONDDATE 'YYYY-MM-DD HH34:MI:SS.FFn'

Numeric Types Tiny Integer TINYINT CS_INT 8-bit unsigned integer, Range 0 To 255

Small Integer SMALLINT CS_INT 16-bit signed integer , Range -32,768 To 32

Integer INTEGER CS_INT 32-bit signed integer, Range -2,147,483,648


2,147,483,647

Big Integer BIGINT CS_FIXED(18,0) 4-bit signed integer , Range -


9,223,372,036,854,775,808 To
9,223,372,036,854,775,807

Decimal DECIMAL(p,s) CS_FIXED(p-s,s) Precision p can range from 1 to 38.

p-Precision The scale s can range from 0 to p.

s- scale If precision and scale are not specified, DEC


becomes a floating-point decimal number.

Small Decimal SMALLDECIMAL CS_SDFLOAT It is a floating-point decimal number. The p


and scale should be within the range 1~16 f
precision and -369~368 for scale, dependin
stored value. SMALLDECIMAL is only suppo
column store Table.
Real Number REAL CS_FLOAT single-precision 32-bit floating-point numbe

Double Number DOUBLE CS_DOUBLE a double-precision 64-bit floating-point num

Float FLOAT(n) CS_DOUBLE It is 32-bit or 64-bit real number. Where n s


the number of bits and should be in the ran
between 1 and 53.

Boolean Boolean BOOLEAN CS_INT TRUE, FALSE And UNKNOWN (NULL).

Character Variable-Length VARCHAR(n) CS_STRING It is a Variable-length character string, whe


String Character String specified the maximum length in bytes and
integer between 1 and 5000.

Variable-Length NVARCHAR(n) CS_STRING Variable-length Unicode character set strin


Unicode <n> indicates the maximum length in chara
character is an integer between 1 and 5000

Alpha Numeric ALPHANUM(n) CS_ALPHANUM Variable length alpha-numeric characters, w


Character indicates the maximum length and is an int
between 1 and 127

Short Text SHORTTEXT(n) CS_STRING It is Variable-length character string which p


text search and string search features. This
can be defined for column store tables, but
row tables.

Binary Types Binary Text VARBINARY(n) CS_RAW Store binary data of a specified maximum le
bytes, where n indicates the maximum leng
an integer between 1 and 5000.
LOB Binary LOB BLOB CS_RAW Large amounts of binary data
Types(Large
Object Types)

Character LOB CLOB CS_STRING ASCII character data

Unicode NCLOB CS_STRING Large Unicode character object


Character LOB

TEXT TEXT CS_STRING The TEXT data type provide text search feat
data type can be defined for column Store t
not for row store tables.

BINARY Text BINTEXT CS_STRING The BINTEXT data type is similar to data typ
Data and thus supports text search features, but
possible to insert binary data. This data typ
defined for column tables, but not for row t

Multi-valued Array ARRAY It stores collections of values of the same d


Types where each element is related with exactly
position. Arrays can contain NULL values as
absence of a value.

SAP HANA Identifiers


Identifiers are used to represent name in SQL statement (e.g. table name, view
name, column name, index name, synonym name, procedure name, function name,
etc.)

There are two types of identifiers – delimited identifiers and undelimited identifiers.

 Delimited Identifiers – It is enclosed in the delimiter, Double Quotes "". The


identifier can contain any character including special character.
 Undelimited Identifiers – Undelimited identifiers (table name, column name)
must start with a letter and cannot contain any symbols other than a digit or
an underscore '_'.
There are two types Quotation mark for delimit as below-

 Single Quotation Mark (' ') – It is used to delimit the string.


 Double Quotation Mark (" ")- It is used for delimiting identifiers.
SAP QM Quality Notifications
By: Priyanka | 21 Jun 2016 6:31 pm | 0 Comments

The SAP System features a central notification system that helps you record and process various
types of inquiries or problems. You can resolve these problems quickly and easily by defining tasks
and assigning them to individuals who will be responsible for implementing them. In addition to
recording and processing these problems, another important objective is to determine where defects
are likely to occur. The integration of the SAP Business Workflow allows you to optimize the
processing activities and reduce processing times.The SAP System features a central notification
system that helps you record and process various types of inquiries or problems. You can resolve
these problems quickly and easily by defining tasks and assigning them to individuals who will be
responsible for implementing them. In addition to recording and processing these problems, another
important objective is to determine where defects are likely to occur. The integration of the SAP
Business Workflow allows you to optimize the processing activities and reduce processing times.
Continuous Process Improvement
The QM Quality notifications can help you and your company fulfill the requirement for continuous
process improvement. In a quality notification, you can record quality-related problems, document
defects and causes confirmed by a defect analysis, define necessary corrective actions to improve
the quality, and monitor the effectiveness of these actions.
Quality Notifications in the Logistics Chain
Delivery Complaints
You can record the problems found in a goods receipt inspection or in the subsequent processing
stages of production by creating a notification for a complaint against the vendor. When you process
a notification, for example, you can create a letter of complaint or an 8D report, activate additional
goods receipt inspections or trigger a return delivery process. The complaint against a vendor also
serves as the basis for determining a complaint score that is used to evaluate a vendor in the
systems vendor evaluation.
Improved Quality through effective Problem Solving
Complaints in Production
If you confirm defects in an inspection during production, if the action limits in a control chart are
exceeded, or if qualitative characteristics are valuated as not OK, you can also record and monitor
these events in a quality notification.
Customer Complaints
If a customer is not satisfied with the goods received in a delivery, you can record the complaint,
inspect the returned goods, analyze the defects and specify the necessary corrective actions to be
taken. You can perform all of these steps using the functions of the quality notifications.
Defects Recording
In defects recording, you can record the defects confirmed in a quality inspection quickly and easily.
These defects are documented and stored as quality notifications in the system.
Elements of the Quality Notification System
Nonconformity Costs
You can use QM orders to record, settle and evaluate the nonconformity costs incurred while
processing a notification problem.
Status Management
Using the system’ s status management function, you can display the current processing status of a
quality notification or task at any time. You can also evaluate any existing notifications and tasks
based on these statuses.
Action Log
All changes that are made in a notification are documented in the system by change documents.
The action log provides an overview of all changes and processing steps in chronological order.
Action Box
Action Box With the help of the action box, you can define follow-up functions that an authorized
person can execute while processing a notification. The action box can be customized to enhance
the notification’ s range of functions and simplify the problem processing activities, and it allows you
to solve problems in a logical sequence.
Document Flow
The document flow provides an overview of all notification-related documents. It allows you to
identify all originating and subsequent documents that relate to a notification.
Notification Structure
A quality notification contains the following elements:
 Notification header: The notification header contains a description of the problem, various
reference objects (for example, material or batch), information relating to complaint quantities and
nonconforming quantities, as well as scheduling dates and status information.
 Notification items: A notification item pinpoints a problem in coded form (for example, a defect type
and defect location) and provides the basis for evaluating the notification data
 Causes: A cause specifies a reason or event that caused a problem to occur and also identifies the
problem to be solved.
 Tasks: A task defines the necessary corrective action(s), responsible organizational units, and
processing deadlines for a notification problem.
 Activity: An activity documents any actions that were carried out in the course of processing a
notification problem
 Partner: A partner is any internal and external person or organizational unit that is directly or
indirectly involved with the notification problem.
Flexible Worklists
Using worklists, you can select and process notifications or tasks on the basis of various selection
criteria. Monitoring functions in the worklist show you the processing status of all selected objects.
Evaluations
The access to central defect and cause catalogs allows you to analyze your quality data on a
company-wide basis in the QM Information System (QMIS) and Business Information Warehouse
(BW). These tools enable you to flexibly select and summarize the data, and display it graphically.
An Early Warning System allows you to automate the search for unusual trends in results and helps
recognize potential problems early
New Technologies

 Notifications on the Internet In the age of electronic commerce, the Internet offers you a wide range
of options for direct communication between customer and vendor. On the Internet, your customer
can record quality notifications quickly and easily. This also allows you to remain in direct contact
with a vendor
 Notifications on the Intranet The employees in your company can use the Intranet to record different
types of inquires or problems, and forward them for further processing. Supported by the SAP
Business Workflow component, the system triggers various internal processes to ensure that the
notification is processed promptly.
 Telephone Integration Using the SAPphone component, you can create a quality notification on the
basis of an incoming telephone call. Outgoing calls can be dialed directly from the SAP System.
 SAP Business Workflow The SAP Business Workflow is a cross-application tool that allows you to
integrate the business tasks across all areas of your company. You can use it to directly notify the
departments or persons who are responsible for processing a given task or notification. This ensures
that all problems are processed quickly and efficiently.
 SAP ArchiveLink: SAP ArchiveLink is an integrated communication interface between the SAP
application components and external electronic archives. You can use this component to archive
printed or electronically transmitted documents and link them to a quality notification.
 Solution Database: When you record and process notifications, you can use the solution database
to quickly find solutions to previously known problems. You can search the database for specific
symptoms and then assign the corresponding solutions to the notification
 Processing Specific Tasks: A person responsible for executing a task in a notification is informed
of the impending work via the SAP Business Workflow or the worklist. Using the function for
processing tasks, this person can call up the task, perform the necessary activities and document
the progress of the work.
mySAP.com Turning Internet Promises into Profit
In the Internet age, businesses in all industries need to move from intra-company integration to
intercompany integration in order to increase competitiveness.
mySAP.com places Web-enabled technology at the heart of all SAP products and services. It
extends the reach of SAP applications into the Internet and enables seamless, end-to-end
integration of both SAP and non-SAP products. mySAP.com creates an open, collaborative business
environment.
mySAP.com also means personalized solutions delivered on demand over the Net. This ensures
that users in all areas of the company receive precisely the functionality and services they need,
when they need them.
By empowering employees, cutting costs, and creating value mySAP.com guarantees business
success.
What is Recurring Inspections type?
In Recurring Inspections type the system can automatically create inspection lots at predefined
intervals for selected batch materials. In other words Recurring Inspections type is used when you
have to inspect the batch material as per the specific time interval.
For e.g if you want that the expiry date of each product has to be inspected at every 6 months...then
if you set up recurring inspection type and enter the inspection interval in material master, then
system will create a inspection lot and you can reject or acccept this batch.
Recurring inspections are triggered by a report that you can execute manually or that the system can
execute automatically (provided it has been planned as a background job). When recurring
inspections are triggered automatically, the background job executes the report, which in turn selects
the batches and creates the inspection lots according to your processing parameters.
The steps for using Recurring inspection type 09.
1) In QM material master view define Inspection Interval.
2) In inspection setup, Activate 09 inspection type by ticking on active.
3) Make quality plan for that material using '09' usage.
4) In QA05 define a variant for recurring inspection lot generation.
5) Select that defined variant and put that material, plant and batch. please tick on " to inspection lot
creation" (in maintain varient screen). If you don't do this lot will not be generated.
6) select the variant and then press schedule tab.
7) click on scedule one / periofically and select the desired frequency.
8) as per defined frequency system will that program and lot will be generated auromatically. If you
want to generate lot immediatly.
9) check the effect of this on that batch, in MSC2N system will display next inspection interval based
on data you maintained.
10) In QA32 put material, batch and 09 type, the lot will be displayed.
Using Digital Signatures in SAP QM to Meet Regulatory Requirements
By: kazama | 08 Jul 2009 6:46 am | 35 Comments

For many SAP customers, the “out of the box” functionality for digital signature should meet their
requirements, particularly in closed systems. If another level of authentication is required, or the
system is open to partners and customers, SAP supports the integration of external security
products (i.e., smart card readers) and the use of public-key technology via the Secure Store &
Forward (SSF) interface (starting with SAP version 4.0b). This is particularly relevant in SAP
applications where digital information is exchanged electronically (i.e., electronic invoices) across
enterprise boundaries.
In these cases, there are two keys involved. The document is signed using a private key, and the
signature is verified using a public key. The private key can be stored on a computer (PC or server)
or on a separate piece of hardware like a smart card. This white paper will focus on “single
key” digital signature authentication. Depending on reader interest, we can potentially follow up this
white paper with a look at the more complex “double key” authentication scenarios.
I. Background on Electronic or “Digital” Signatures
SAP defines a “Digital Signature” in the online documentation as follows:
Logistics - General (LO)
Equivalent to a handwritten signature for the processing of digital data.
The digital signature ensures that:
 The signed transaction can only be carried out by users with a special authorization
 The signatory identification is unique and forgery-proof
 The signatory name is documented together with the signed transaction and the date and time, and
cannot be falsified
The Quality Management (QM) application component uses the simple signature. This means, that a
document is signed or approved by the signature of a single authorized person.
You can use the digital signature for the following functions:
 During results recording
 At the usage decision
 When confirming the physical sample drawing. This means, when releasing the first physical sample
in a physical sample drawing.
II. Configuration (using the IMG)
General Settings:
In order to use the Digital Signature functionality, you must first define the “General Settings.”
A) Time Zones
(standard SAP setting should suffice here—see Figure 1)
Figure 1: Maintain Time Zone
B) Assign Personal Time Zone (maintain User Defaults)
The “Personal Time Zone” for your User ID must be maintained. This assures that the signature
date and time are correct for the individual user who “signs” the document.
This can be done using the following menu path System → User profile → Own data (or
transaction SU3. Make sure to click on the “Defaults” tab (see Figure 2).

Figure 2: Assign Personal Time Zone to User ID


In this example, the system time zone is Eastern Standard Time (EST), but my user is located in
California on Pacific Standard Time (PST).
C) Signature Method
There are two main options for the Signature Method (Listed below as 1. and 2.). For this white
paper, we use Option 1 (System signature with authorization by SAP User ID and password). This
option is only available from R/3 Version 4.6c forward.
1. System signature with authorization by SAP User ID and password
As noted by SAP: “Here, you do not need an external security product. Just like when logging on to
the system, users identify themselves by entering their User IDs and passwords. The SAP system
then executes the digital signature. The user name and ID are part of the signed document.”
This signature method is available “out of the box” and requires no additional hardware.
To configure the signature method, use the IMG to navigate to “Define Authorization Groups and
Digital Signature” (see Figure 3).

Figure 3: IMG Menu Path to Signature Method


Once in the “Specify Signature Method for Simple Signature” Table, click on the “New Entries”
button.
In the Signature object type field, we select the entries for “Inspection Lot: Results Recording” and
“Inspection Lot: Usage Decision” (see Figure 4).
Figure 4: Assign Signature Object Type
In the Signature Method, field we select “System signature with authorization by R/3 user
ID/password” (see Figure 5).

Figure 5: Assign System Signature as Method


When finished, the two rows you added should look like this:

Figure 6: Two Added Entries


2. User signature with and without verification
SAP notes: “Here, you need an external security product. Users execute digital signatures
themselves using their private keys. The signature created by the security product is automatically
checked for authenticity.” This is done using the Secure Store and Forward (SSF) interface, which
makes use of Public-Key Cryptographic Standards (PKCS). http://help.sap.com
*NOTE - In this white paper, we do NOT use an external security product; therefore I will not
detail the customizing settings for the (SSF) interface. For reference, they can be found in the
IMG under: SAP Web Application Server → System Administration → Digital Signatures
(menu path for SAP 4.7)
D) QM Material Authorization Group:
Quality Management (QM) in SAP is primarily a material-based system. The QM view of the
Material Master is set up at an “organizational level” of “Plant.” This means that the general Quality
Control settings are activated based on a combination of Material and Plant. The case with digital
signatures is also the same. In order to activate the digital signature in QM, you must configure an
authorization group in the QM View of the Material Master. This can be done in the following area of
the IMG (same menu path as for Signature Method—see Figure 7):
Figure 7: IMG Menu Path to Mat. Auth Group
n this table, you can change an existing entry or add a new entry to create a QM Material
Authorization Group based on your requirements. For our example, we will add QM Material
Authorization Group 000099 with the following settings:
 Approval for Inspection Lot – approval not required
 Digital Signature in Results Recording – required for results recording
 Digital Signature at Usage Decision – required for making the usage decision
 Digital Signature for Sample Drawing – not required

Figure 8: Entry Added for Digital Signature at RR & UD


Although not used in this white paper, notice that there is the ability to require a digital signature for
the approval of the inspection lot and the physical sample drawing. The “Approval insp. lot” setting
can require a digital signature for the approval of an inspection lot and depends on whether a task
list (i.e., inspection plan) or material specification is used. There is also the ability here to require a
digital signature for the confirmation of a physical sample drawing.
Additionally, there is NOT a setting for Quality Notifications in this table. (Quality Notifications are not
always based on a Material.) The digital signature for Quality Notifications is currently not available
in Standard SAP (as of Release 4.7). This functionality could be added via a Business Add-In or
“BAdI” as some SAP customers have done.
III. Master Data
A) Adding the QM Material Auth. Group to the QM View of the Material
Next we will add the QM Material Auth Group that we just created in Configuration to the QM View of
the Material Master. As I stated earlier, the QM View is set up at an Organizational level of plant. I
have an existing Material Master 10005723 that we will change via Transaction MM02 (see Figure
9).

Figure 9: QM View of Material Master


Next, select the plant at which you want to change the QM Settings:

Figure 10: Organizational Level of Plant


Then, add QM Material Authorization Group 000099:
Figure 11: QM Auth Group in Material Master
QM Auth Group. 000099, which we created earlier, will require a Digital Signature anytime we record
results or make a usage decision for an inspection lot (for this material/plant combination—see
Figure 12).

Figure 12: Entry Added


B) Reviewing the Inspection Data Setup:
In order to use the digital signature functionality, we must have the material set up to create an
inspection lot. In this example, we have a Material Master that represents a semi-finished material
that requires inspection at Goods Receipt from Production. In order to see the settings maintained
for this material, click on the “Insp. setup” button:
Figure 13: QM Inspection Data Setup
You can see in the above screenshot that I have added Inspection Lot Origin 04 and activated it.
The details for Inspection Lot Origin 04 are shown in the bottom half of the screen. In this example,
we require that SAP create an inspection lot for the Goods Receipt from a production order and
allow “early lot creation” at Production Order Release.
IV. Inspection Processing (Results Recording & Usage Decision)
In order to see the digital signature functionality in action, I have created an inspection lot.
A) Digital Signature at Results Recording
The digital signature for results recording happens at the time the user saves the results for the
Operation (digital signature is at the Operation Level). In this example, a digital signature is required
for results recording (for the material/plant combination). This means that when the results are
saved, SAP will now ask the user to verify his unique identity. A digital signature will be required for
every operation that results are recorded against (e.g., 3 Operations = 3 Signatures). SAP will
automatically record the associated Inspection Lot and Operation number in the “remarks” section:
Figure 14: Digital Signature for Results Recording
The digital signature method we are using utilizes the SAP User ID and Password. This means that
the person recording the results must enter their unique User ID (Signatory) and its associated
Password in order to proceed. SAP will verify that the password is correct for that User ID, and then
execute the digital signature—at which time the user name and ID become part of the signed
document. If the password is incorrect, SAP will issue a message and allow the user to try again (up
to the number of allowed attempts configured). In the case of too many failed attempts, SAP will lock
the User ID.

Figure 15: Error, Incorrect Password


It is possible to change the signatory to another User ID (the password must be correct for that User
ID). This can be helpful in the case where a supervisor may need to sign off the results for one of her
inspectors. The “Comment” section can be used for documentation. It is possible to change the
signatory to another User ID (the password must be correct for that User ID). This can be helpful in
the case where a supervisor may need to sign off the results for one of her inspectors. The
“Comment” section can be used for documentation.
B) Digital Signature at Usage Decision
The digital signature at Usage Decision happens at the time the user saves or changes a Usage
Decision (transaction QA11 and QA12). This can happen for the stock posting or Usage Decision
Code.
When the Usage Decision is saved, the Digital Signature box will appear:

Figure 16: Digital Signature at Usage Decision


SAP automatically records the inspection lot number. The user can enter comments if needed and
again must enter his unique User ID (Signatory) and its associated Password in order to proceed.
V. Audit Trail
A) Digital Signature Logs
Lastly, SAP provides a transaction to review the digital signature logs. This is accessed via
Transaction DSAL. As this is a common transaction that is used for multiple applications, you must
select the application “inspection lot” to narrow down the entries (see Figure 17).
Figure 17: Digital Signature Logs (Selection Screen)
Using this transaction, you can search for signatures of a particular Signatory (User ID), as well as
look for signatures for a particular Date Range or Inspection Lot (see Figure 18). The transaction can
also find unsuccessful attempts (e.g., user locked, wrong password, etc.).

Figure 18: Digital Signature Log (Output)


The following log shows the successful signature for the usage decision—notice that the Global
date/time of the signature differ from Local signature date/time:

Figure 19: Digital Signature Log (Detail)


VI. Conclusion
In the past, SAP customers have found it challenging to prove that the Inspector who logged onto
their SAP system was indeed the same Inspector (User) who recorded the results. This can often
happen because many SAP users share a common desktop PC and leave it logged-on to SAP
under one user’s account. With the digital signature, a user is required to enter the
signatory/password combination that is only known to that user. The value here is that the “digital
signature” proves to the business and regulatory authorities that the inspectors entering results in
QM are who they say they are (just as an inspector’s stamp or written signature would).
As mentioned at the beginning of the white paper, the digital signature also helps SAP customers
meet GMP guidelines as well as FDA 21 CFR Part 11 (for customers in the medical industry).
Although the FDA is currently revising 21 CFR Part 11, they fully expect that companies using
electronic records will take the needed steps to be in full compliance when the latest guidelines are
released. As non-compliance can lead to fines and costs in millions of dollars, the cost of ignoring
these issues can be steep. SAP, as well as their customers, has made compliance a priority.
How to prevent deleting TSCO tasks of notifications?
SOLUTION
In order to avoid deleting TSCO tasks of notifications, you have to create a user status profile and
a user status which will prevent deleting the task. Then assign the user status profile to the related
notification type.
Please follow the steps below:
 First, create a user status profile in BS02 and assign object type 'Tasks'.
 Now create 2 users status

 One will allows completing tasks and deleting tasks

 The other user status will be set once tasks are completed. It will prohibit deleting tasks.
 Now assign the user status profile to the notification type. Customizing path t-code QCC2 -> Quality
Notifications -> Notification Processing -> Status Management -> Define Status Profile ->
Status Profile for Notification Type :

After performing all the setting above the result will look like as shown below:
 First please create a new notification in transaction code QM01.
 Now create a task. It is a system status is TSOS and user status is dele.
 Complete the task: The system status will become TSCO and user status will become NODE.

 Now when you try to delete the task. A status error will popup which will avoid the deletion.

Potrebbero piacerti anche