Dnia 2004-02-13 05:53, Użytkownik Kumar napisał:
> I am having problem there. see what happens
>
> sqlstr := 'insert into test(c1, c2) values ('||COALESCE(rec.c1,'NULL')||','
> ||'\''||rec.c2||'\')';
You are preparing a string, so make sure you have strings everywhere:
sqlstr := 'insert into test(c1, c2) values
('||COALESCE(rec.c1::text,'NULL')||','||'\''||rec.c2||'\')';
Regards,
Tomasz Myrta