all groups > sql server reporting services > july 2006 >
You're in the

sql server reporting services

group:

I lost it!! SQL parameter datetim formula



I lost it!! SQL parameter datetim formula michelk
7/10/2006 12:00:00 AM
sql server reporting services: Hai ,

Can anybody say it's not me ?

tried it in VS2003 and VS2005 but can't get it working. It seems easy ...
I have created a report with a sql stored procedure as dataset. Droped a
table on the report. Run the report . See the data. OK.
But one of the report parameters is the month (as int) So i what to set a
default value for this parameter. I type in the "default values" in
"non-queried" the following formula "=Month(Today)". The formula compiler
says it's OK. But when i run the report I'm seeing Nothing!!! What I'm
missing here.???
Spend 1hour trying.. please help. Is this a bug?

michel



RE: I lost it!! SQL parameter datetim formula Jeff Ericson
7/10/2006 6:22:01 AM
Did you change filed names between the report and the data set? I've done
that and the report returns no errors but no data.

[quoted text, click to view]
Re: I lost it!! SQL parameter datetim formula Perry
7/10/2006 4:02:30 PM
Michel,

Can you try
=Month(Now())

Instead of what you are using currently. This is what I always use for
getting the monthnumber and never gave me a hard time.

grtz

Perry



[quoted text, click to view]

Re: I lost it!! SQL parameter datetim formula Bruce L-C [MVP]
7/11/2006 1:39:48 PM
When developing an expression I do one of two things. Either I have a report
with a single textbox that I assign the expression to so I can see the
result or I have a little vb.net app that I use to test the vb.net code.

That being said, I quickly did this and it worked no problem.

Do this.
1. create new report (blank, nothing on it).
2. add a parameter of type int
3. set the Default values non-queried to this
=Month(now())

No quotes put exactly the above
4. Preview


--
Bruce Loehle-Conger
MVP SQL Server Reporting Services



[quoted text, click to view]

Re: I lost it!! SQL parameter datetim formula michelk
7/11/2006 8:25:50 PM
Thanks for responding.

I did it all. All possible combinations . Without luck. ;-)
The only thing i'm getting is a grayedout input box. ??? The report with
data is working ok. Even when I create a new parameter (int) with this
formula it's still grayed out ????
If this is the beginning of using SQL reporting service then I'm staying at
crystal reports ... (even when I don't want that to..)

can someone send me a RDL that works ?


[quoted text, click to view]

Re: I lost it!! SQL parameter datetim formula michelk
7/12/2006 12:00:00 AM
Ok its working ;-)
The problem was that there is a parameter (type string) that was doing
something.. If this parameter was standing above any parameter with the
month function all the parameters with functions where grayed out... complex
explanation .. but anyway it works...

I'm in the middle of converting 20 crystal reports to reporting service....

THANKS

[quoted text, click to view]

AddThis Social Bookmark Button