Write a PL/SQL program to Add Number in a word (a0b1c2d3) - Computer Programming

Latest

C C++ Java Python Perl Programs Examples with Output -useful for Schools & College Students

Thursday, October 5, 2017

Write a PL/SQL program to Add Number in a word (a0b1c2d3)

Add Number in a word (a0b1c2d3)  PL/SQL 

Program:

DECLARE

PROCEDURE sent_data(name VARCHAR2)
IS
extract_data CHAR;
BEGIN
FOR i IN 1 .. LENGTH(name)
LOOP
extract_data := SUBSTR(name,i,1);
dbms_output.put( extract_data || (i-1));
END LOOP;
dbms_output.new_line;
END;

BEGIN
sent_data('abcd');

END;

No comments:

Post a Comment