> I'm porting some stored procedures from a MSSQL server, and thought I'd
> use PL/pgSQL.
>
> The original code is checking the insert with the line:
>
> if (@@Error != 0)
You might want to use something like:
SELECT INTO variable_name *
FROM table
WHERE field = some_value;
IF FOUND THEN
somevar := variable_name.fieldname ;
ELSE
RAISE EXCEPTION ''ERROR blah blah'';
END IF;
And you also want to look into the @@rowcount:
GET DIAGNOSTICS v_rowcount = ROW_COUNT ;
Reinoud
---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])