DEFINITIONS
Definitions More Info.
Definition ID
837
Title
POSTGRESQL
Category
NOTES
Definition
WHILE loop example
Definition Description
CREATE OR REPLACE FUNCTION "twhile"( INTEGER,INTEGER )
RETURNS INTEGER AS $body$
DECLARE i INTEGER;
$p INTEGER;
BEGIN i := 0;
WHILE( i <= $p ) loop INSERT
INTO
public."customer" ( cname,
clastname,
phone,
adress ) SELECT
cname,
clastname,
phone,
adress
FROM
public."tcustomer";
i = i + 1;
END loop;
RETURN i;
RecordBy
cunay
Record Date
03-06-2018 14:07:52
Düzenle
Kopyala
Sil