Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Mon, 21 Apr 2003 @ 12:23:44 GMT


     
  <Prev Next>   <<First <Prev
Next>
Last>>
 


Subj:   Re: Stored procedure warning..
 
From:   Jaganathan, Rameshkumar

I believe this will help you

REPLACE  PROCEDURE spsample4()
BEGIN
  DECLARE v_num INTEGER;
  DECLARE v_empcode  varchar(6);
  DECLARE v_basic DEC(10,2);
     FOR CustCursor AS c_customer CURSOR FOR
        SELECT num,empcode,basic FROM EMPLOYEE
       DO
        SET v_num = CustCursor.num;
        SET v_empcode = CustCursor.empcode;
        SET v_basic = CustCursor.basic;
        INSERT INTO test_emp (num,empcode,basic)  VALUES
(:v_num,:v_empcode,:v_basic);
   END FOR;
END;

Ramesh



     
  <Prev Next>   <<First <Prev
Next>
Last>>
 
 
 
 
 
 
 
 
 
  
  Top Home Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 15 Jun 2023