Blog Author
Tekslate
Published Date
22nd September, 2020
Ratings
Views
781
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
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
By providing command KS_LS_L
Note: This command is used to verify RAPID ANALYTICS files (TABLES, Land scopes, views)
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
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 Instance number
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%
a) For multi-line mode will write long commands on several lines.
HDBSQL stores multiple lines command in the internal command buffer.
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
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
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
TekSlate
TekSlate is the best online training provider in delivering world-class IT skills to individuals and corporates from all parts of the globe. We are proven experts in accumulating every need of an IT skills upgrade aspirant and have delivered excellent services. We aim to bring you all the essentials to learn and master new technologies in the market with our articles, blogs, and videos. Build your career success with us, enhancing most in-demand skills .
Write For Us