1
votes

I am trying to pass Schema Name as Report Parameters While Writing SQL Query in "Telerik Reporting Designer Configure Data Source Command Window".

The Orignal Query is this (its working fine in Command Windows)

SELECT
[8f2175c0-7021-4286-86ec-f2dd627fdc73].[QuizActivity].[ID], 
[8f2175c0-7021-4286-86ec-f2dd627fdc73].[QuizActivity].[RowID]
FROM [8f2175c0-7021-4286-86ec-f2dd627fdc73].[QuizActivity]

But If I write this query to get result based on Schema Parameter, I received an error

SELECT
@SchemaName.[QuizActivity].[ID], 
@SchemaName.[QuizActivity].[RowID]
FROM @SchemaName.[QuizActivity]

Incorrect Syntax near QuizActivity

my default value is [8f2175c0-7021-4286-86ec-f2dd627fdc73]

Screenshot of Configure Data-source Command Window

Reporting Designer Parameter Configuration

What should I do resolve this issue?

1

1 Answers

0
votes

You can try to escape the value: ="\[8f2175c0-7021-4286-86ec-f2dd627fdc73\]"

Reference: https://docs.telerik.com/reporting/expressions-global-objects