Recent changes to DB null handling?

Stimulsoft Reports.NET discussion
Post Reply
Peter Illes
Posts: 18
Joined: Tue Jun 26, 2007 8:04 am
Location: Hungary

Recent changes to DB null handling?

Post by Peter Illes »

Hi,

It seems to me that there might be a newly introduced bug in 2007.2 / recent versions (I see this with the latest): when a field is null, things used to work, but now I get strange errors like get_XXXX cannot cast DBNull, and when I pass the column to a function (my Lookup()) then the function is not called at all if the column is null, instead that part is aborted (there must be a silent exception lurking in there).

Any ideas?

TIA,
Peter
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Recent changes to DB null handling?

Post by Vital »

Please provide more details for this error (full error stack, report, report code).

Thank you.
Peter Illes
Posts: 18
Joined: Tue Jun 26, 2007 8:04 am
Location: Hungary

Recent changes to DB null handling?

Post by Peter Illes »

Vital,

I have a Text control with the following Text value:

Code: Select all

{ "Country:" + Lookup(PARTNER2.BILLINGCOUNTRY_ID, COUNTRY, "DESCRIPTION") }
Now if PARTNER2.BILLINGCOUNTRY_ID is null, then Lookup() will not be called, and the whole control will be empty. This used be OK (Lookup() handles nulls inside).

TIA,
Peter
Edward
Posts: 2913
Joined: Fri Jun 09, 2006 4:02 am

Recent changes to DB null handling?

Post by Edward »

Is the HideZeroes property of the Text component set in true? Please check it.

Thank you.
Peter Illes
Posts: 18
Joined: Tue Jun 26, 2007 8:04 am
Location: Hungary

Recent changes to DB null handling?

Post by Peter Illes »

Edward: no, HideZeroes == false.
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Recent changes to DB null handling?

Post by Vital »

Report with sample data possible?
Post Reply