Subject Re: [firebird-support] check if a select return value
Author Martijn Tonies
Hi,

> Hi, I have this select in my stored procedure
>
> select ID_CURSO, ID_PARCEIRO from MATRICULA
> where ID_CONTRATO = :ID_CONTRATO
> into :CURSO_ANTERIOR, :ID_PARCEIRO
>
> How can I check if the select has been returned a value?
>
> the variables CURSO_ANTERIOR and ID_PARCEIRO are integers and doesn't
> have any assignment of values before this select.
>
> If my select doesn't return any value, what will be assigned to my
> variables?

The previously assigned value.

It if was NULL, it stays NULL. If it was X, it stays X.

With regards,

Martijn Tonies
Database Workbench - the developer tool for InterBase & Firebird
Upscene Productions
http://www.upscene.com