Showing posts with label export. Show all posts
Showing posts with label export. Show all posts

Tuesday, March 27, 2012

Creating A3 size reports for PDF export

Hello,

I would like to create "big" reports designed for printing. I have to get a pdf version of the reports.

When I try to use the pdf format, the report appears to be truncated to match the A4 paper size, instead of the bigger A3 design I made.

Do you have experience on this problem? What can I do?

Thank you

David

to display the report in A3 it to so easy just make the Pages size 42cm*59.4cm it will give the required paperssql

Thursday, March 22, 2012

Creating A tab delimited export

Hello all,

I am trying customize the CSV rendering extension with different device information settings. I would loke to change the CSV extension to a Tab delimited output. However, whenever I add a new extension line to the RSReportServer.config file I run into problems.

1. What is the correct character to use in the delimiter to specify a Tab character? I seem to be unable to get this correct

2. Why when I override the name in the rendering extension does it still show up as the CSV (comma delimited) name in the export dropdown.

Here is my customized rendering extension.

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name>TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<Encoding>ASCII</Encoding>
<FieldDelimiter><![CDATA[#x9]]></FieldDelimiter>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

Thanks

Justin

Justin,

1. For tab-delimited report, use

<FieldDelimiter>&#9;</FieldDelimiter>

2. For name override, you must specify language attribute:

<Name Language="en-US">TXT (Tab Delimited Text File)</Name>

(more info on http://msdn2.microsoft.com/en-us/library/ms156281.aspx)

Thanks!

|||

Denis,

Thanks for your response. This got me halfway there. The Language attribute worked beautifully but the Field Delimiter didn't seem to make any difference.

The ouput defaulted back to a comma delimiter.

Here is my revised config file

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name Language="en-US">TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<FieldDelimiter>&#9;</FieldDelimiter>
<Extension>TXT</Extension>
<Encoding>ASCII</Encoding>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

and the only line in the log files that seemed to relate to this request.

aspnet_wp!cache!1!9/5/2006-22:33:30:: v VERBOSE: Key not found in cache: __RenderedSnapshotResult__:/AdvancedReports/AscribeExportReport&0a14be41-8afb-4c74-b8ce-6a8d80aade69&&Format:TXT&Extension:TXTEncoding:ASCIINoHeader:true:__PrimaryStream__

Thanks again prompt reply,

Justin

|||

Justin,

Unfortunately, Reporting Services currently trims all special characters from configuration file device info values. So, single TAB character got trimmed out when configuration file got parsed.

The work around to get a tab-separated file is to pass &rc:FieldDelimiter=%09 via URL access.

Thanks!

|||does this include encoding this in a cdata section?|||This is not really a viable workaround for anyone using the Reporting Services Interface. Yeah we could put a link on a report pointing to the URL, but this is inconsistent and users won't understand why. So is it our only option then to go and write our own rendering extension to accomplish something that's already done?

Creating A tab delimited export

Hello all,

I am trying customize the CSV rendering extension with different device information settings. I would loke to change the CSV extension to a Tab delimited output. However, whenever I add a new extension line to the RSReportServer.config file I run into problems.

1. What is the correct character to use in the delimiter to specify a Tab character? I seem to be unable to get this correct

2. Why when I override the name in the rendering extension does it still show up as the CSV (comma delimited) name in the export dropdown.

Here is my customized rendering extension.

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name>TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<Encoding>ASCII</Encoding>
<FieldDelimiter><![CDATA[#x9]]></FieldDelimiter>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

Thanks

Justin

Justin,

1. For tab-delimited report, use

<FieldDelimiter>&#9;</FieldDelimiter>

2. For name override, you must specify language attribute:

<Name Language="en-US">TXT (Tab Delimited Text File)</Name>

(more info on http://msdn2.microsoft.com/en-us/library/ms156281.aspx)

Thanks!

|||

Denis,

Thanks for your response. This got me halfway there. The Language attribute worked beautifully but the Field Delimiter didn't seem to make any difference.

The ouput defaulted back to a comma delimiter.

Here is my revised config file

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name Language="en-US">TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<FieldDelimiter>&#9;</FieldDelimiter>
<Extension>TXT</Extension>
<Encoding>ASCII</Encoding>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

and the only line in the log files that seemed to relate to this request.

aspnet_wp!cache!1!9/5/2006-22:33:30:: v VERBOSE: Key not found in cache: __RenderedSnapshotResult__:/AdvancedReports/AscribeExportReport&0a14be41-8afb-4c74-b8ce-6a8d80aade69&&Format:TXT&Extension:TXTEncoding:ASCIINoHeader:true:__PrimaryStream__

Thanks again prompt reply,

Justin

|||

Justin,

Unfortunately, Reporting Services currently trims all special characters from configuration file device info values. So, single TAB character got trimmed out when configuration file got parsed.

The work around to get a tab-separated file is to pass &rc:FieldDelimiter=%09 via URL access.

Thanks!

|||does this include encoding this in a cdata section?|||This is not really a viable workaround for anyone using the Reporting Services Interface. Yeah we could put a link on a report pointing to the URL, but this is inconsistent and users won't understand why. So is it our only option then to go and write our own rendering extension to accomplish something that's already done?sql

Creating A tab delimited export

Hello all,

I am trying customize the CSV rendering extension with different device information settings. I would loke to change the CSV extension to a Tab delimited output. However, whenever I add a new extension line to the RSReportServer.config file I run into problems.

1. What is the correct character to use in the delimiter to specify a Tab character? I seem to be unable to get this correct

2. Why when I override the name in the rendering extension does it still show up as the CSV (comma delimited) name in the export dropdown.

Here is my customized rendering extension.

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name>TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<Encoding>ASCII</Encoding>
<FieldDelimiter><![CDATA[#x9]]></FieldDelimiter>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

Thanks

Justin

Justin,

1. For tab-delimited report, use

<FieldDelimiter>&#9;</FieldDelimiter>

2. For name override, you must specify language attribute:

<Name Language="en-US">TXT (Tab Delimited Text File)</Name>

(more info on http://msdn2.microsoft.com/en-us/library/ms156281.aspx)

Thanks!

|||

Denis,

Thanks for your response. This got me halfway there. The Language attribute worked beautifully but the Field Delimiter didn't seem to make any difference.

The ouput defaulted back to a comma delimiter.

Here is my revised config file

<Extension Name="TXT" Type="Microsoft.ReportingServices.Rendering.CsvRenderer.CsvReport,Microsoft.ReportingServices.CsvRendering">
<OverrideNames>
<Name Language="en-US">TXT (Tab Delimited Text File)></Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<FieldDelimiter>&#9;</FieldDelimiter>
<Extension>TXT</Extension>
<Encoding>ASCII</Encoding>
<NoHeader>true</NoHeader>
</DeviceInfo>
</Configuration>
</Extension>

and the only line in the log files that seemed to relate to this request.

aspnet_wp!cache!1!9/5/2006-22:33:30:: v VERBOSE: Key not found in cache: __RenderedSnapshotResult__:/AdvancedReports/AscribeExportReport&0a14be41-8afb-4c74-b8ce-6a8d80aade69&&Format:TXT&Extension:TXTEncoding:ASCIINoHeader:true:__PrimaryStream__

Thanks again prompt reply,

Justin

|||

Justin,

Unfortunately, Reporting Services currently trims all special characters from configuration file device info values. So, single TAB character got trimmed out when configuration file got parsed.

The work around to get a tab-separated file is to pass &rc:FieldDelimiter=%09 via URL access.

Thanks!

|||does this include encoding this in a cdata section?|||This is not really a viable workaround for anyone using the Reporting Services Interface. Yeah we could put a link on a report pointing to the URL, but this is inconsistent and users won't understand why. So is it our only option then to go and write our own rendering extension to accomplish something that's already done?

Wednesday, March 7, 2012

Creating a formated text file from a query

Hello all.
I'm not highly experienced with SQL programming. I must export to contents
of a table to a formated text file which is then send to the customer. Is
there a possibility to do this from within a sql statement?
TIA
RonaldHi Ronald,
You can call the BCP utility from your SQL code. The BCP utility
enables you to export a table or query results to a file. You should
consult Books Online for information about BCP and find what
switches/options are suitable to your situation.
Now, normally you would call BCP from a command line (e.g. a DOS
prompt) but you can also call it from SQL code by going:
exec master..xp_cmdshell 'bcp <rest goes here>'
Note that by default only users in the SysAdmin fixed server role can
call xp_cmdshell.
Hope that helps a bit|||Yes
1)Use BCP to create the file - make sure all permissions are set up.
2)You can send the email from within the sp - SQL server has some built in
functionality or you can install 3rd party dll such as
http://www.sqldev.net/xp/xpsmtp.htm
--
Jack Vamvas
___________________________________
Receive free SQL tips - www.ciquery.com/sqlserver.htm
___________________________________
"Ronald Hermans" <rhermans@.datamedicare.nl> wrote in message
news:OuwKwAAdGHA.536@.TK2MSFTNGP02.phx.gbl...
> Hello all.
> I'm not highly experienced with SQL programming. I must export to contents
> of a table to a formated text file which is then send to the customer. Is
> there a possibility to do this from within a sql statement?
> TIA
> Ronald
>|||Ive read this question and i want something similar..but automatic.
I say every friday sql creates a text file with the contents from a
table, and sends to the server for the client can download it from the
internet..
It can be done with BCP too?|||encase your stored procedure AS as a JOB . Make sure you place the file in
the correct destination and naming is correct for download.
Will your client be downloading from a web site?
--
--
Jack Vamvas
___________________________________
Receive free SQL tips - www.ciquery.com/sqlserver.htm
___________________________________
"Pp" <josemariabarros@.gmail.com> wrote in message
news:1147255005.925240.12610@.j33g2000cwa.googlegroups.com...
> Ive read this question and i want something similar..but automatic.
> I say every friday sql creates a text file with the contents from a
> table, and sends to the server for the client can download it from the
> internet..
> It can be done with BCP too?
>|||Yes. it will put a username and password to enter in a administration
web site and then he can download it|||Thanx,
That did the trick.
"Ronald Hermans" <rhermans@.datamedicare.nl> schreef in bericht
news:OuwKwAAdGHA.536@.TK2MSFTNGP02.phx.gbl...
> Hello all.
> I'm not highly experienced with SQL programming. I must export to contents
> of a table to a formated text file which is then send to the customer. Is
> there a possibility to do this from within a sql statement?
> TIA
> Ronald
>