Example—Singleton Select
The following example represents a singleton select. Given an account number, it selects information about a customer from a table that contains customer information:
declare
cname = varchar(100) not null;
cphone = varchar(10) not null;
enddeclare
{
...
/*
**/Given an account number, get customer information
*/
select cname as :cname,
cphone as :cphone
from customer
where acctnum = :account_number;
...
}