Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 Display no row when no data is returned

Author  Topic 

1sabine8
Posting Yak Master

130 Posts

Posted - 2010-05-19 : 12:02:46
Hi,

I have a table where i put in each data columns a condition that if there is no data in this column to display "No information".

What's happening is that even when the query returns no data, i am having a row in the table with all values shown as "No information".

In this case, i need to display the columns header titles without any row data.

How can i do that?

Thanks in advance

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2010-05-19 : 12:43:28
The easiest way may be a column that must have a value if there is at least one row.
So for this column you don't have to make the condition with "No information".
That should work.


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-05-19 : 12:50:09
quote:
Originally posted by 1sabine8

Hi,

I have a table where i put in each data columns a condition that if there is no data in this column to display "No information".

What's happening is that even when the query returns no data, i am having a row in the table with all values shown as "No information".

In this case, i need to display the columns header titles without any row data.

How can i do that?

Thanks in advance



what is expression set for column? have you set any values for no rows property of table?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

1sabine8
Posting Yak Master

130 Posts

Posted - 2010-05-20 : 03:18:42
Hi,
Here's my expression:
=IIF(Fields!Cities.Value = "NULL","No Information",Fields!Cities.Value)
Actually the condition is if the value ="Null" because in the database it's a string where we're filling the string "Null".
So how can i achive what i need?
I found a NoRowsMessage property but not i dont need to display any message, i just need to show just the column headers.
Go to Top of Page
   

- Advertisement -