--
-- ### User defined rounding procedure dec2int
--

drop if exists table t1;
create table t1 ( a decimal(2) );

drop if exists procedure dec2int;
@
create procedure dec2int(a in decimal(2)) return int
begin
	var i int;
	:i = :a;
	return :i;
end;
@

insert into t1 values ( 1.63 );
insert into t1 values ( 1.99 );
insert into t1 values ( 1.11 );
insert into t1 values ( 1.23 );
select dec2int(a), a from t1;
