Add limit op_predef.od_description
This commit is contained in:
parent
8d1dea9c07
commit
e891cde641
1 changed files with 15 additions and 0 deletions
|
|
@ -261,3 +261,18 @@ $BODY$
|
|||
$BODY$
|
||||
LANGUAGE plpgsql VOLATILE
|
||||
|
||||
create or replace function comptaproc.opd_limit_description()
|
||||
returns trigger
|
||||
as
|
||||
$BEGIN$
|
||||
declare
|
||||
sDescription text;
|
||||
begin
|
||||
sDescription := NEW.od_description;
|
||||
NEW.od_description := substr(sDescription,1,80);
|
||||
return NEW;
|
||||
end;
|
||||
$BEGIN$
|
||||
LANGUAGE plpgsql;
|
||||
|
||||
create trigger opd_limit_description before update or insert on op_predef execute procedure for each row comptaproc.opd_limit_description();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue