0
votes

I'm creating a fairly simple report in Report Builder 3.0 that requires a filter for part numbers between two user-specified values, both of which are taken from a list of existing part numbers. Before I added a filter, everything ran perfectly fine-- no errors with either of my two parameters(which are under the "Parameters" folder in report data, not the "Parameters" section within dataset properties). Although, after adding it and trying to run the report, I receive an error that reads:

The report parameter ‘pnPromptField1’ has a DefaultValue or a ValidValue that depends on the report parameter “pnPromptField1”. Forward dependencies are not valid.

I've tried messing around with the default and available value sections under the parameter properties, but nothing I do seems to work. All of the properties for both parameters are default, minus the name/prompt and the available values, which both have options set to "Dataset: inv, Value field: pn, Label field: pn".

The fact that everything ran smoothly before the introduction of a filter is what confuses me most, as nothing was changed in the report at all with the exception of the filter being added. The filter's properties are "Expression: [pn], text(unchangeable), Operator: Between, Value: [@pnPromptField1] & [@pnPromptField2]

Any and all help is appreciated, I'm still new to SQL and pretty much anything related to it. Thanks in advance

2
If you remove the filter (and do nothing else), does it start working again? - Tab Alleman
@TabAlleman Yes, it does - NDV
There's no typo in your error message? The pnPromptField1 parameter is dependent on itself? Is anything dependent on the DataSet that is being filtered? - Tab Alleman
@TabAlleman The filter itself depends on the dataset, as a field must be chosen from the dataset. I've found that after switching the "available values" option for both paras to "none" while still keeping the filter, the report runs... I think I'm beginning to see where the possible loop could be: the filter depends on the value selected in pnPromptFields 1 and 2, but the available values that can be shown and chosen depend on the results that pass through the filter... That would be kind of a dumb way for the program to work, if that is the way, but I can't think of any other possibility atm. - NDV
You will probably have to use two datasets, even though they use the same query/proc, with one of them dependent on the other. I have had to do this in the past to avoid similar issues. - Tab Alleman

2 Answers

0
votes

You've put a filter on a dataset, and made that filter dependent on the same dataset. Due to way SSRS handles this, this means that you basically made your dataset dependent on itself, which SSRS doesn't like for obvious reasons.

I don't know if there are other ways around it, but the way I have handled similar issues in the past is to make two datasets, even though they are both using the same query or proc, and make one dataset dependent on the other.

0
votes
The report parameter ‘pnPromptField1’ has a DefaultValue or a ValidValue that depends on the report parameter “pnPromptField1”. Forward dependencies are not valid.

This Error occurs when One parameter depends on the other Parameter value. for example if you have first parameter 'pnPromptField1' that depends on the 'pnPromptField'. In design time you have added 'pnPromptField1' after 'pnPromptField' then it will through you error.

so you have to check the Order of Parameter that you added to your reports.

'pnPromptField' 'pnPromptField1'---this parameter depends on above one.

not like this

'pnPromptField1' 'pnPromptField'---this through you error 'dependency'.