You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was having an argument with the guys from llblgenpro. They said that there is no way to know if a stored procedure parameter is nullable or not. I disagreed, since in firebird this seems to work. I tried proving them wrong.
I made a stored procedure that contains all possible declarations of a parameter to me.
create procedure SMURF (
IN_NULLABLE_BOOL D_BOOL,
IN_NOT_NULLABLE_BOOL D_BOOL_NN,
IN_NULLABLE_BOOL2 type of D_BOOL,
IN_NOT_NULLABLE_BOOL2 type of D_BOOL_NN,
IN_NULLABLE_BOOL3 smallint,
IN_NOT_NULLABLE_BOOL3 smallint not null,
IN_NULLABLE_BOOL4 type of column T_PRODUCT_STOCK.F_PRS_STRICT,
IN_NOT_NULLABLE_BOOL4 type of column T_PRODUCT_STOCK.F_PRS_ACTIVE)
as
begin
/* Procedure Text */
suspend;
end
Submitted by: Alexander Muylaert (alexander_gonline.be)
Attachments:
test.xml
Hi Jiri
I was having an argument with the guys from llblgenpro. They said that there is no way to know if a stored procedure parameter is nullable or not. I disagreed, since in firebird this seems to work. I tried proving them wrong.
I made a stored procedure that contains all possible declarations of a parameter to me.
create procedure SMURF (
IN_NULLABLE_BOOL D_BOOL,
IN_NOT_NULLABLE_BOOL D_BOOL_NN,
IN_NULLABLE_BOOL2 type of D_BOOL,
IN_NOT_NULLABLE_BOOL2 type of D_BOOL_NN,
IN_NULLABLE_BOOL3 smallint,
IN_NOT_NULLABLE_BOOL3 smallint not null,
IN_NULLABLE_BOOL4 type of column T_PRODUCT_STOCK.F_PRS_STRICT,
IN_NOT_NULLABLE_BOOL4 type of column T_PRODUCT_STOCK.F_PRS_ACTIVE)
as
begin
/* Procedure Text */
suspend;
end
and then I asked for the schema information.
Attached you'll find the test.xml. It looks to me that the syntax used for IN_NOT_NULLABLE_BOOL3 doesn't return the correct flag for IsNullable.
<ProcedureParameters>
<PROCEDURE_NAME>SMURF</PROCEDURE_NAME>
<PARAMETER_NAME>IN_NOT_NULLABLE_BOOL3</PARAMETER_NAME>
<PARAMETER_DATA_TYPE>smallint</PARAMETER_DATA_TYPE>
<PARAMETER_SUB_TYPE>0</PARAMETER_SUB_TYPE>
<ORDINAL_POSITION>5</ORDINAL_POSITION>
<PARAMETER_DIRECTION>1</PARAMETER_DIRECTION>
<PARAMETER_SIZE>2</PARAMETER_SIZE>
<NUMERIC_PRECISION>0</NUMERIC_PRECISION>
<NUMERIC_SCALE>0</NUMERIC_SCALE>
<CHARACTER_OCTET_LENGTH>0</CHARACTER_OCTET_LENGTH>
<IS_NULLABLE>true</IS_NULLABLE>
</ProcedureParameters>
is this something fixable?
Thanks
Alexander
Commits: aa9e546
The text was updated successfully, but these errors were encountered: