SAP HANA Database Management

Log on to Linux environment

We can connect the Linux environment by using “EXTRA PUTTY” interphase

Double click on EXTRA PUTTY Provide ID address of LINUX Environment

Select combo box ʘ SSH to Linux environment with security connection

We will get a command prompt for the LINUX environment

Provide Use name & password

Log on to HANA Database in Linux Environment

Provide command “SU -- <Sid> dam” so, we can connect to HANA Database so we will get the path as below

<host> : HDB : <Sid> adm / usr / sap / HAN HDB XK >

XX – instance number

Verify files in HANA DB

By providing command KS_LS_L

Note: This command is used to verify RAPID ANALYTICS files (TABLES, Land scopes, views)

Logon to HANA Database client Interphase

SAP HANA HDB SQL command line cool for entering SQL Statements for executing database procedures and query information about SAP HANA Database

You can Use HDBSQL interactively or import commands from external files and execute them in the background.

 

Inclined to build a profession as SAP HANA Developer? Then here is the blog post on, explore SAP HANA Training

Features

Executing SQL statements

Executing Database procedures

Requesting information about database catalog

Executing commands

Overview of HDBSQL dr call options and commands

Provide command “HDBSQL – ixx – U (User’s:)

P (password)

   ↓

Instance   Untitled    Instance number

Executing Commands

SAP has provided some SQL commands to per form

Operations on HANA DB

/dc [PATTERN] list columns

/de [PATTERN] list indices

/dp [PATTERN] list procedures

/ds [NAME]         list Selenium

/dl [PATTERN] list tables

/du [NAME]      list users

/dv [PATTEREN] list views

[PATTERN] = [OWNER] [OBJECT NAME]    g  <User name>, % A%

multi line mode and editing commands in external file

a) For multi-line mode will write long commands on several lines.

HDBSQL stores multiple lines command in the internal command buffer.

 

SAP HANA Tutorials

 

Activities in buffers

Displaying the contents of the command buffer p

Deleting the contents of the command buffer /r

Editing command in an External file

Executing the command buffer : /g

External file

By providing statement VI – filename .sql so, will get editor we can write multiple commands to manage HANA database.

Managing HANA database is meant by managing schemas, creating tables and managing tables.

Example:- After finishing our code we need to press “Esc” on keyboard and type “wq”

CREATE TABLE CITY

(Zip NCHAR (5) primary key,

Name NCHAR (20),

State NCHAR (2));

CREATE TABLE Customer

(CNO INTEGER PRIMARY KEY,

Title NCHAR (7),

First name NCHAR (10),

Name NCHAR (10),

Zip NCHAR (5),

Address NCHAR (25) );

/DT CUSTAMER;

COMMIT

Redirecting results on-screen  or to an external file

Executing external file on the screen

Provide statement “hdbsql –i52-- p>

“hdbsql – i52 – u <user id> - p<password) – z <file name>

Will get output on the screen

Redirecting output to an external file

Provide statement ‘hdbsql – i52 – U <user id> -- P <password>

F<file name> /sql O{filename> out

Displaying contents of external files (input, output) files  to display

To see the file contents provide commands

Input file                             more <file name> .SQL

Output file                          more <file name> .OUT

For an In-depth knowledge on SAP HANA, click on below