The correct syntax for JOINing to an SP would be:

select
  regioni _ID,
  stored_procedure_value
from regioni
  left outer join stored_procedure (:DATE1,:DATE2) ON 1 = 1   <--


Sean

From: [email protected] [mailto:[email protected]]
Sent: November-19-14 9:25 AM
To: [email protected]
Subject: [firebird-support] Left outer join with stored procedure



Hello All,

I have a table regioni with 164 rows (r_id), and also stored procedure which 
returns some data like (r_id, value).
When I try to use

select

regioni _ID,
stored_procedure_value

from regioni
left outer join stored_procedure (:DATE1,:DATE2)

I only get number 20 rows for the R_ID which is returned by procedure. I cant 
manage to get all 164 rows from regioni table matched with values from 
stored_procedure, where value exists.

Can someno help with this ?

Regards,

Zoran






Reply via email to