Subject Re: [firebird-support] Firebird vs. PostgreSQL
Author Martijn Tonies (Upscene Productions)
Hello Alexey,

>What about compilation of stored procedures - is it true that it is
>possible to create SP with errors, and they appear only when it will be
>invoked?

Yes, some errors are 'allowed', like a mismatch in parameter name in
declaration and code. You'll get an error when executing, eg:

' column "p_inventory_id2" does not exist '

A wrong variable name as the target for an assignment, however, isn't
allowed.

>Also, about checking the parameters - is it true that you can create
>stored procedure which invokes other stored procedure with wrong list of
>parameters, and it will give error only at the execution time?

Yes, correct. Example:
CREATE OR REPLACE FUNCTION public.last_day(Timestamp)

Call v_d = last_day(); results in:
' function last_day() does not exist '

PostgreSQL supports multiple stored routine languages out of the box: 'sql'
and 'plpgsql', with different (weird) syntax.

And it supports parameter overloading > functions with the same name but
a different number of parameters.

Also, triggers are different > you need a stored function that returns
'trigger',
and when creating a trigger, you assign it that function. Triggers don't
have
code.


Hope this helps.


With regards,

Martijn Tonies
Upscene Productions
http://www.upscene.com


On 07.11.2018 19:27, 'Martijn Tonies (Upscene Productions)'
m.tonies@... [firebird-support] wrote:
> Yes, it's true and it's rather annoying when, for example, developing an
> interactive database development tool;)



------------------------------------

------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu. Try FAQ and other links from the left-side menu
there.

Also search the knowledgebases at
http://www.ibphoenix.com/resources/documents/

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

Yahoo Groups Links