• USA : +1 973 910 5725
  • INDIA: +91 905 291 3388
  • info@tekslate.com
  • Login

Procedures in Teradata

Procedures

 

Creating

Create procedure<procedure name>(<PARAMS>)As. BEGIN<SQL Queries>END;

 

Replacing

Replace procedure<procedure name>(<PARAMS>)As. BEGIN<SQL Queries>END;

 

DROPING

DROP procedure<procedure name>

 

View

SHOW Procedure<procedure name>

At TekSlate, we offer resources that help you in learning various IT courses. We avail both written
 material and demo video tutorials. To gain in-depth knowledge and be on par with practical
 experience, then explore Teradata Training Videos.

 

Calling

Call procedure<procedure name>(<PARAMS>)

 

Example

Create procedure (Dcone1 INTEGER,DName1 varchar(30))

BEGIN

DECLARE DEPTNAME VARCHAR(30);

SET DEPTNAME=DNAME1;

INSERT INTO DEPT(DCODE, DNAME)Values(:Dcode1,:DEPT NAME);

END;

Call p – sample(70,‘IT’);

Select* From Dept;

Check out the top Teradata Interview Questions now!

Example

Create procedure SP(PID INTEGER, out op INTEGER)

BEGIN

DECLARE VAR1 INTEGER;

SELECT Party income into:var1 from party where party =pid;

Select op=var1*10;

END;

Call SP(1,OP)

For Indepth knowledge on Teradata click on:

 

Summary
Review Date
Reviewed Item
Procedures in Teradata
Author Rating
5

“At TekSlate, we are trying to create high quality tutorials and articles, if you think any information is incorrect or want to add anything to the article, please feel free to get in touch with us at info@tekslate.com, we will update the article in 24 hours.”

0 Responses on Procedures in Teradata"

Leave a Message

Your email address will not be published. Required fields are marked *

Site Disclaimer, Copyright © 2016 - All Rights Reserved.