Re: [Firebird-devel] Stored procedures example

2020-02-04 Thread Alex Peshkoff via Firebird-devel
On 2020-02-03 20:44, Adriano dos Santos Fernandes wrote: On 03/02/2020 12:45, liviuslivius wrote: Hi It really should be rewritten/updated. 1. First select should use new type join kind not comma join kind. 2. Field po_number should be prefixed with alias of the table. 3. Order of exception and

Re: [Firebird-devel] Stored procedures example

2020-02-03 Thread Adriano dos Santos Fernandes
On 03/02/2020 12:45, liviuslivius wrote: > Hi > > It really should be rewritten/updated. > 1. First select should use new type join kind not comma join kind. > 2. Field po_number should be prefixed with alias of the table. > 3. Order of exception and update should be reverted, sussped removed, > al

Re: [Firebird-devel] Stored procedures example

2020-02-03 Thread Adriano dos Santos Fernandes
On 03/02/2020 13:16, Leyne, Sean wrote: > >   > > 3. Order of exception and update should be reverted, sussped removed, > also maybe this update should be run in autonomous transaction but > this is not nescessary as someone can commit after this error. > >   > > AFAIK, an Exception “kills/termina

Re: [Firebird-devel] Stored procedures example

2020-02-03 Thread Leyne, Sean
It really should be rewritten/updated. 1. First select should use new type join kind not comma join kind. +1 2. Field po_number should be prefixed with alias of the table. +1 3. Order of exception and update should be reverted, sussped removed, also maybe this update should be run in autono

Re: [Firebird-devel] Stored procedures example

2020-02-03 Thread liviuslivius
transaction but this is not nescessary as someone can commit after this error.Regards,Karol Bieniaszewski Oryginalna wiadomość Od: Adriano dos Santos Fernandes Data: 03.02.2020 16:16 (GMT+01:00) Do: For discussion among Firebird Developers Temat: [Firebird-devel] Stored

[Firebird-devel] Stored procedures example

2020-02-03 Thread Adriano dos Santos Fernandes
Hi! In employee examples, there this kind of stored procedures: --- CREATE PROCEDURE ship_order (po_num CHAR(8)) AS     DECLARE VARIABLE ord_stat CHAR(7);     DECLARE VARIABLE hold_stat CHAR(1);     DECLARE VARIABLE cust_no INTEGER;     DECLARE VARIABLE any_po CHAR(8); BEGIN     SELECT s.orde