/*
Derby - Class org.apache.derbyTesting.functionTests.harness.procedure
Copyright 2003, 2004 The Apache Software Foundation or its licensors, as applicable.
Licensed under the Apache Lice
const a=45,b=27;
var x,y,g,m :integer;
procedure swap;
var temp:integer;
begin
temp:=x;
x:=y;
y:=temp;
end
procedure mod;
x=x-x/y*y;
begin
x:=a;
y:=b;
while x 0
do
begin
swap;
const a=45,b=27;
var x,y,g,m :integer;
procedure swap;
var temp:integer;
begin
temp:=x;
x:=y;
y:=temp;
end
procedure mod;
x=x-x/y*y;
begin
x:=a;
y:=b;
while x 0
do
begin
swap;
This example demonstrates how to call stored procedures with IN, OUT, and IN/OUT parameters.
CallableStatement cs;
try {
// Call a procedure with no parameters
cs = connecti
A stored procedure or function can be created with no parameters, IN parameters, OUT parameters, or IN/OUT parameters. There can be many parameters per stored procedure or function.
An IN parameter
create procedure up_books_info
as
select title, type, price, pub_name
from titles
inner join publishers
on titles .pub_id = publishers.pub_id
where pub_name like 'B%' and price >