Вопрос

I have a multivalue parameter that is populated from a query that returns an Id (UNIQUEIDENTIFIER) column and a Label (VARCHAR) column. I set the parameter to have a Text type, to use Id as the Value field and Label as the Label field and it works fine.

Now I want to set a few default values so that when the report is run, these values will be checked by default. In the Default Values tab, I have tried entering the Id values without quotes, with single quotes, and with double quotes, as well as trying the Label values without quotes, with single quotes, and with double quotes. However, in all cases none of the items are checked with I run the report.

I do not want to Get values from a query, I want to Specify values. How can I make this work?

Это было полезно?

Решение

I have also ran into this problem, specifying default values to a Unique identifier is not supported (I cannot find any source to back this up, just my own experience).

Is there a specific reason why you cannot use Get values from a query?

The solution user1578107 addresses will also work, use a convert to pass a varchar(36) to your parameter:

select convert(varchar(36),Id)
from table
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top