SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 ssrs export to csv file problem
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

jassie
Constraint Violating Yak Guru

295 Posts

Posted - 01/03/2014 :  12:07:16  Show Profile  Reply with Quote
Whenever I export an ssrs 2008 or ssrs 2012 report to comma delimited file, all columns are always displayed. I have code setup to hide the column when there is not data in the column.

I am using the following code:

=IIF(First(Len(Fields!CustomerNumber.Value)) > 0,False,true)

I the column level visibility,I have also set the DataElementOutput=Output for the textbox that displays the value.

The above code works when I export the ssrs report to excel.


Thus can you tell me what I can do to get the column not to be displayed when the file is exported to csv (comma delimited) file?

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 01/04/2014 :  05:26:09  Show Profile  Reply with Quote
what about this?

=IIF(First(Len(Fields!CustomerNumber.Value)) > 0 Or Globals!RenderFormat.Name != "CSV",False,true)


------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 01/04/2014 :  05:36:06  Show Profile  Reply with Quote
Also one more thing?
Shouldnt you be setting property as
DataElementOutput=NoOutput to make it not rendering for CSV format?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000