Nullable int (int?) in parameter passed to dialog returns no results in datagrid filter

Greetings, and May the 4th be with you!

I have a table with a foreign key (int) value that is set to a parameter and is expected to be passed to a dialog. The int value is used to filter a grid in the dialog. For some reason the parameter returns null when the dialog is loaded, even though the the foreign key exists. The IDE shows the value type as 'Int?' which I know to be nullable int. If I manually set the parameter to the actual interger that the foreign key is instead of using the foreign key's table property, it works as expected. I will also note that if I used the parameter in one of the grid's header columns in the dialog, removing the 'parameters' portion (combinedframeworkId), it does display the Id. What are common causes of this behavior? I have other grids and parameters configured in exactly the same way that dont seem to have this issue. I am using sqlite database, dotnet 6 and Radzen IDE 2.68.6. Could this be a bug? I have not had this issue before.

Dialog Grid with parameter value passed to header, but returning null in the filter:

IDE & variable:

Database Entry:

Dialog Parameter:
image

Dialog Load event 'get' filter:

If I replace ${combinedframeworkID} with direct values from the table like '7' or '8', it functions as expected and loads the correct grid items. Otherwise, nothing loads. I have alternatively tried appending .getValueOrDefault(), .Value, and done a check for .HasValue on the variable and parameter in which case all three return null.

To expand on this, I am now actually noticing that none of my datagrid filters in any dialog or page that contain int? values are returning results anymore. They were working very recently. I am feeling more confident now that this is a bug. I updated to 2.68.6 a couple of days ago. The previous version I was using had a similar bug that would call an exception when trying to hide or unhide a column that contained a template with a button with parameters to a dialog so going back is not an option.

@Andrew, what if you get rid of the null somehow? For example in the Set combinedframeworkid part of your Invoke use

${result.CombinedFrameworkId > 0 ? result.CombinedFrameworkId : 0}

Also, found this - Nullabletype error DataGrid with Update 2.68.6- 2022-04-27 - Radzen IDE (Blazor server-side) - Radzen

@SloSuenos, thanks unfortunately this isn't really an option since none of the values are actually null and I need the Id which is supposed to be getting passed. returning a 0 would result in the same behavior which would be an empty grid as none of my framework Ids are null or 0.

Also, what you suggested is essentially the behavior of getValueOrDefault().

@Andrew, well I learned something new! So, when you use getValueOrDefault() the Property Type changes correctly from nullable int to non-nullable int? I ask because the Property Type in the GUI doesn't always update itself correctly and can need some manual intervention.

If getValueOrDefault() is working and the int? is getting set to an int, then how could it subsequently turn null? Doesn't make sense.

Also could you have set combinedframeworkId to global somewhere? Inadvertently mixing has caused me problems, and I ask because I don't see how you could have filtered the grid on a separate page without the 'parameters' potion unless you'd set combinedframeworkId to a global.

All I can suggest is stepping through the code with Visual Studio while watching the parameter to see if or where or when the value changes.

That's just it. Regardless of the condition I use, the result is returning a null, which is telling me that the int itself isn't even being propagated to the dialog.

Second thing you mention is incorrect. I am not passing the parameter to a page. I do use global variables for those actions. I am passing the int parameter to a dialog. Dialogs are activated within the same page in the form of an overlay.

Essentially, there is a break somewhere between the parameter being set and the dialog accessing it. It almost acts like its being ignored entirely which is why it seems like a bug.