Professional Documents
Culture Documents
--------------------------
The SAP HANA database has its own scripting language named SQLScript.
Syntax:
CREATE TABLE "PRACT"."JAYANT"
(
"EMPID" INTEGER NOT NULL PRIMARY KEY ,
"EMPNM" VARCHAR(20)
);
IMP POINT :By default it will create Row store Table .For coloumn table we have to
define "COLUMN".
NB:The DELETE statement deletes records from a table where the <condition> is met.
If the WHERE clause is omitted, then DELETE removes all records from a table.
SELECTING DATA :( SELECT CLAUSE & FROM CLAUSE )
----------------
Syntax:
Select * from <table_name>; -- here * indicates all columns
or
Select col1, col2, coln from <table_name>;
Example :
SELECT "region_code","region_name","SUB_REGION_NAME"
from "PRACT"."PRO_REGION";
SELECT
A."region_code",A."region_name",A."SUB_REGION_NAME",
B."product_id",B."sales_amount"
from
"PRACT"."PRO_REGION" AS A
JOIN
"PRACT"."PRO_SALES" AS B
ON
A."region_code" = B."region_code";