<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://sqlblog.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Roman Rehak</title><link>http://sqlblog.com/blogs/roman_rehak/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2.1 SP2 (Build: 61129.1)</generator><item><title>Presenting at Montreal SQL Server User Group</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2011/05/23/presenting-at-montreal-sql-server.aspx</link><pubDate>Mon, 23 May 2011 18:11:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:35819</guid><dc:creator>roman</dc:creator><slash:comments>0</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/35819.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=35819</wfw:commentRss><description>Tomorrow (5/24) I will be presenting at the Montreal SQL Server User Group meeting. It's a double topic presentation - Introduction to SQL Azure, and SQL Server Reporting Services Programming . It's the usual meeting place, the Microsoft building at 6:30....(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2011/05/23/presenting-at-montreal-sql-server.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=35819" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/presenting/default.aspx">presenting</category></item><item><title>SQL Saturday #59 followup</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/11/22/sql-saturday-59-followup.aspx</link><pubDate>Mon, 22 Nov 2010 04:15:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:30862</guid><dc:creator>roman</dc:creator><slash:comments>0</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/30862.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=30862</wfw:commentRss><description>My session at SQL Saturday #59 went great, the room was packed with people sitting on the floor. The only thing I didn't like was that I had to compress 75 minutes to 50. My apologies to Allan Hirt for not getting out quickly, I got a little carried away...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/11/22/sql-saturday-59-followup.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=30862" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Saturday/default.aspx">SQL Saturday</category></item><item><title>Speaking at SQL Saturday #59 in New York City</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/11/18/speaking-at-sql-saturday-59-in-new-york-city.aspx</link><pubDate>Fri, 19 Nov 2010 02:10:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:30760</guid><dc:creator>roman</dc:creator><slash:comments>1</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/30760.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=30760</wfw:commentRss><description>I will be presenting this weekend at SQL Saturday #59 in NYC, doing my favorite session SQL Server Development Tips and Tricks. The schedule for this event looks very good. Looks like the event is "sold out" so I expect pretty good attendance, especially...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/11/18/speaking-at-sql-saturday-59-in-new-york-city.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=30760" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Saturday/default.aspx">SQL Saturday</category></item><item><title>PASS 2010 afterthoughts</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/11/15/pass-2010-afterthoughts.aspx</link><pubDate>Mon, 15 Nov 2010 21:31:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:30610</guid><dc:creator>roman</dc:creator><slash:comments>0</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/30610.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=30610</wfw:commentRss><description>Last week I was in Seattle at PASS, just like everyone else that's at least remotely interested in SQL Server. Here is a collection of miscellanous thoughts and observations: - This was my summit #10. I still recall my first PASS ten years ago in San...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/11/15/pass-2010-afterthoughts.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=30610" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/PASS/default.aspx">PASS</category></item><item><title>Moving SQL Server aliases to another computer</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/11/07/moving-sql-server-aliases-to-another-computer.aspx</link><pubDate>Sun, 07 Nov 2010 20:06:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:30250</guid><dc:creator>roman</dc:creator><slash:comments>2</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/30250.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=30250</wfw:commentRss><description>I utilize SQL Server aliases a lot, especially since for some reason I don't get name resolution on our network over VPN. So I typicaly create an alias and map the name to the IP address of each SQL Server I use a lot on the network. I am in the process...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/11/07/moving-sql-server-aliases-to-another-computer.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=30250" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/aliases/default.aspx">aliases</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/Tips/default.aspx">Tips</category></item><item><title>SQL Azure free trial extended till March 31st 2011</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/11/04/sql-azure-free-trial-extended-till-march-31st-2011.aspx</link><pubDate>Thu, 04 Nov 2010 15:05:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:30172</guid><dc:creator>roman</dc:creator><slash:comments>0</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/30172.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=30172</wfw:commentRss><description>If you are interested in checking out SQL Azure for free, they just extended the trial period till 3/31/2011. What it boils down to is that you get to have a 1GB web database free of charge for 3 months, Good deal if you want to evaluate what this Azure...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/11/04/sql-azure-free-trial-extended-till-march-31st-2011.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=30172" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Azure/default.aspx">SQL Azure</category></item><item><title>Issues with 2008 to R2 upgrade</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/10/28/issues-with-2008-to-r2-upgrade.aspx</link><pubDate>Thu, 28 Oct 2010 16:34:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:29932</guid><dc:creator>roman</dc:creator><slash:comments>11</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/29932.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=29932</wfw:commentRss><description>I was recently upgrading a production server to R2 and it turned out to be a fairly frustrating, and in the end unsuccessful experience. This was the Standard Edition. The installer popped a message and said that the system needed to be rebooted due to...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/10/28/issues-with-2008-to-r2-upgrade.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=29932" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Server+2008+R2/default.aspx">SQL Server 2008 R2</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/upgrade/default.aspx">upgrade</category></item><item><title>SQL Saturday #39 in NYC</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/04/20/sql-saturday-39-in-nyc.aspx</link><pubDate>Wed, 21 Apr 2010 01:06:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:24435</guid><dc:creator>roman</dc:creator><slash:comments>1</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/24435.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=24435</wfw:commentRss><description>This weekend I will be speaking at the NYC SQL Saturday . The whole event was supposed to be BI focused but now the schedule shows a lot of non BI stuff as well. I will be presenting SQL Server 2008 Reporting Services Programming , one of my favorite...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/04/20/sql-saturday-39-in-nyc.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=24435" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/presenting/default.aspx">presenting</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Saturday/default.aspx">SQL Saturday</category></item><item><title>SQL Saturday Boston 2010</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/01/31/sql-saturday-boston-2010.aspx</link><pubDate>Sun, 31 Jan 2010 14:49:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:21646</guid><dc:creator>roman</dc:creator><slash:comments>2</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/21646.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=21646</wfw:commentRss><description>Yesterday I presented my "SQL Server Development Tips and Tricks" session at SQL Saturday #34 in Boston. Here are some of my thoughts and observations: I've been crazy busy the last two weeks and only got some time to work on my session Friday evening....(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/01/31/sql-saturday-boston-2010.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=21646" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Saturday/default.aspx">SQL Saturday</category></item><item><title>Your work may not be lost</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2010/01/28/your-work-may-not-be-lost.aspx</link><pubDate>Thu, 28 Jan 2010 15:22:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:21561</guid><dc:creator>roman</dc:creator><slash:comments>16</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/21561.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=21561</wfw:commentRss><description>One of the things that I found dissapointing in Management Studio 2008 is that in the event of a crash (and in addition to crashing in the first place), is that on a restart it doesn't show me a dialog with a list of auto-saved files, like my SSMS 2005...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2010/01/28/your-work-may-not-be-lost.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=21561" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/bugs/default.aspx">bugs</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/SQL+Server+Management+Studio/default.aspx">SQL Server Management Studio</category></item><item><title>OT: Corrupted Outlook file</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2009/11/13/ot-corrupted-outlook-file.aspx</link><pubDate>Fri, 13 Nov 2009 18:10:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:18827</guid><dc:creator>roman</dc:creator><slash:comments>1</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/18827.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=18827</wfw:commentRss><description>This is not a SQL Server post but it might be beneficial to some of you. Over the last few months I've been having huge issues with Outlook 2007. Aside from running like molasses on a cold day, it consistently crashes a few times a week. Instaling the...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2009/11/13/ot-corrupted-outlook-file.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=18827" width="1" height="1"&gt;</description></item><item><title>Backup compression no longer Enterprise edition only</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2009/11/11/backup-compression-no-longer-enterprise-edition-only.aspx</link><pubDate>Wed, 11 Nov 2009 23:10:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:18747</guid><dc:creator>roman</dc:creator><slash:comments>1</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/18747.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=18747</wfw:commentRss><description>Last week at PASS I had a discussion with a program manager on the SQL Server team and he told me that in SQL Server 2008 R2, backup compression will be available in the Standard edition. I suspect this announcement will leave many of you very happy....(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2009/11/11/backup-compression-no-longer-enterprise-edition-only.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=18747" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/backup+compression/default.aspx">backup compression</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/editions/default.aspx">editions</category></item><item><title>PASS 2009 recap</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2009/11/07/pass-2008-recap.aspx</link><pubDate>Sat, 07 Nov 2009 22:33:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:18631</guid><dc:creator>roman</dc:creator><slash:comments>1</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/18631.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=18631</wfw:commentRss><description>This week I was at PASS just like many other folks from here. Good times as always, although less partying than in the past. Since I am still in recovery and relying on Percoset to get me through the day, I was wiped every evening. Here are a few thoughts...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2009/11/07/pass-2008-recap.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=18631" width="1" height="1"&gt;</description><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/Conference/default.aspx">Conference</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/PASS/default.aspx">PASS</category><category domain="http://sqlblog.com/blogs/roman_rehak/archive/tags/Reporting+Services/default.aspx">Reporting Services</category></item><item><title>Issue with restoring 2000 backups on 2008</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2009/11/02/issue-with-restoring-2000-backups-on-2008.aspx</link><pubDate>Mon, 02 Nov 2009 19:22:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:18475</guid><dc:creator>roman</dc:creator><slash:comments>0</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/18475.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=18475</wfw:commentRss><description>Recently we've been experiencing a lot of headaches with SQL Server 2008 crashing while restoring a backup taken on a SQL Server 2000 production server. The crash resulted in a stack dump but SQL Server would continue running, although less stable, and...(&lt;a href="http://sqlblog.com/blogs/roman_rehak/archive/2009/11/02/issue-with-restoring-2000-backups-on-2008.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=18475" width="1" height="1"&gt;</description></item><item><title>SSRS report rendering from command prompt</title><link>http://sqlblog.com/blogs/roman_rehak/archive/2009/06/12/ssrs-report-rendering-from-command-prompt.aspx</link><pubDate>Sat, 13 Jun 2009 01:53:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:14626</guid><dc:creator>roman</dc:creator><slash:comments>14</slash:comments><comments>http://sqlblog.com/blogs/roman_rehak/comments/14626.aspx</comments><wfw:commentRss>http://sqlblog.com/blogs/roman_rehak/commentrss.aspx?PostID=14626</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;A while ago I posted on what now seems to be a defunct blog site, SQL Junkies, a blog about how you can use the RS scripting utility to generate SQL Server Reporting Services reports from command line prompt. In preparation for the DevTeach conference I decided to resurrect it for a demo and since a few things changed between SSRS 2000 and SSRS 2008, it required some work and digging through books online. One of the changes was that starting with SQL Server 2005, Reporting Services provides two separate web service endpoints. The ReportService2005 service is used for management and administrative functions, and the ReportExecution2005 service contains functions related to report rendering. By default, RSS script connects to the management endpoint but in this case since I wanted to use the render function, I needed to connect to the other endpoint. So, the trick here is to use the new endpoint (–e) switch parameter and specify RsExec2005 to use the execution endpoint instead.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;Here is a code sample showing rendering from the command prompt, the following DOS command runs the utility against specified report server (-s parameter) and instructs it to execute a file that follows the –I parameter. The third parameter specifies the execution endpoint:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT face=Calibri size=3&gt;rs -i "c:\temp\reports\Render Report.rss" -s &lt;/FONT&gt;&lt;A href="http://rrehak/ReportServer_Katmai"&gt;&lt;SPAN style="mso-bidi-font-family:'Times New Roman';mso-bidi-theme-font:minor-bidi;"&gt;&lt;FONT face="Times New Roman" size=3&gt;http://rrehak/ReportServer_Katmai&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt; -e Exec2005&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;The RSS utility will render a report (I am using one of the sample Adventure Works reports) and save the rendered file in MS Excel format. The contents of the Render Report.rss file look like this, you may need to modify to match your path to the report:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;Public Sub Main()&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim format as string = "EXCEL"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim fileName as String = "C:\temp\reports\Product Line Sales.xls"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim reportPath as String = "/AdventureWorks 2008 Sample Reports/Product Line Sales 2008"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;' Prepare Render arguments&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim historyID as string = Nothing&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim deviceInfo as string = Nothing&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim extension as string = Nothing&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim encoding as string &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim mimeType as string &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim warnings() AS Warning = Nothing&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim streamIDs() as string = Nothing&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim results() as Byte&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;rs.LoadReport(reportPath, historyID)&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;results = rs.Render(format,&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;deviceInfo, extension, _&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;mimeType, encoding,&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;warnings, streamIDs)&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;' Open a file stream and write out the report&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;Dim stream&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;As FileStream = File.OpenWrite(fileName)&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;stream.Write(results, 0, results.Length)&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp; &lt;/SPAN&gt;stream.Close()&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;End Sub&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0in 0in 0pt;"&gt;&lt;o:p&gt;&lt;FONT face=Calibri size=3&gt;&lt;/FONT&gt;&lt;/o:p&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://sqlblog.com/aggbug.aspx?PostID=14626" width="1" height="1"&gt;</description></item></channel></rss>