Showing posts with label method. Show all posts
Showing posts with label method. Show all posts

Thursday, March 22, 2012

Exporting a topic from BOL

Is there an easy method to export a topic out of BOL?

For example ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/instsql9/html/309b9dac-0b3a-4617-85ef-c4519ce9d014.htm

I'd like to export this to MS Word, I need to send this information to a large distrubtion list for review and I'm find it rather diffucult. Sending the entire BOL files is not a option.

A satifactory option would be to load BOL to Windows SharePoint Services. I'd want the enitre document to be load not just an copy that a user would install on thier local workstation.

Here are a couple of possibilities.

1. Assuming everyone on the distribution list has internet access, you may want to send them a link to the equivalent topics located on MSDN. For example, the topic you referenced can be found here: http://msdn2.microsoft.com/en-us/library/ms143504(SQL.90).aspx. The main entry point to BOL is here: http://msdn2.microsoft.com/en-us/library/ms130214(SQL.90).aspx.

or

2. Copy/paste the topic into Word. In the BOL topic, right-click and choose Select All. Right-click again and choose Copy. Open Word and paste into an open document. The formatting is a bit odd, but it may be satisfactory for your needs. The links to other topics won't work of course.

What we do in our group is download Books Online to a single server and then have users access the server using Remote Desktop. That might be an alternative for you also.

Regards,

Gail

Wednesday, March 21, 2012

Exportin table in xml file

Hello everyone,
I need to save data into an xml file. Now I do this with Visual Basic using
the ado-recordset method 'Save'. I'd like to do this task with a sql server
stored procedure.
Does anyone know if it is possible, and how?
--
Thank you everyoone,
Walker BohYou could do something like
EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
' -od:\FTPresentation\imagefmt.fmt'
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> Hello everyone,
> I need to save data into an xml file. Now I do this with Visual Basic
using
> the ado-recordset method 'Save'. I'd like to do this task with a sql
server
> stored procedure.
> Does anyone know if it is possible, and how?
> --
> Thank you everyoone,
> Walker Boh|||It doesn't work as I need. It doesn't create an xml file that I can open wit
h
IE for example, nor it has tha same structure the recordset methis save
create.
thank you anyway
"Wayne Snyder" wrote:

> You could do something like
> EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
> ' -od:\FTPresentation\imagefmt.fmt'
>
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
> news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> using
> server
>
>

Exportin table in xml file

Hello everyone,
I need to save data into an xml file. Now I do this with Visual Basic using
the ado-recordset method 'Save'. I'd like to do this task with a sql server
stored procedure.
Does anyone know if it is possible, and how?
Thank you everyoone,
Walker Boh
You could do something like
EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
' -od:\FTPresentation\imagefmt.fmt'
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> Hello everyone,
> I need to save data into an xml file. Now I do this with Visual Basic
using
> the ado-recordset method 'Save'. I'd like to do this task with a sql
server
> stored procedure.
> Does anyone know if it is possible, and how?
> --
> Thank you everyoone,
> Walker Boh
|||It doesn't work as I need. It doesn't create an xml file that I can open with
IE for example, nor it has tha same structure the recordset methis save
create.
thank you anyway
"Wayne Snyder" wrote:

> You could do something like
> EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
> ' -od:\FTPresentation\imagefmt.fmt'
>
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
> news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> using
> server
>
>

Exportin table in xml file

Hello everyone,
I need to save data into an xml file. Now I do this with Visual Basic using
the ado-recordset method 'Save'. I'd like to do this task with a sql server
stored procedure.
Does anyone know if it is possible, and how?
--
Thank you everyoone,
Walker BohYou could do something like
EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
' -od:\FTPresentation\imagefmt.fmt'
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> Hello everyone,
> I need to save data into an xml file. Now I do this with Visual Basic
using
> the ado-recordset method 'Save'. I'd like to do this task with a sql
server
> stored procedure.
> Does anyone know if it is possible, and how?
> --
> Thank you everyoone,
> Walker Boh|||It doesn't work as I need. It doesn't create an xml file that I can open with
IE for example, nor it has tha same structure the recordset methis save
create.
thank you anyway
"Wayne Snyder" wrote:
> You could do something like
> EXEC master..xp_cmdshell "OSQL -E -S -Q"Select * from table for xml
> ' -od:\FTPresentation\imagefmt.fmt'
>
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Walker Boh" <WalkerBoh@.discussions.microsoft.com> wrote in message
> news:F1F0C715-25E3-4337-99E6-4CF4F0DDEF49@.microsoft.com...
> > Hello everyone,
> >
> > I need to save data into an xml file. Now I do this with Visual Basic
> using
> > the ado-recordset method 'Save'. I'd like to do this task with a sql
> server
> > stored procedure.
> > Does anyone know if it is possible, and how?
> > --
> > Thank you everyoone,
> > Walker Boh
>
>

ExportData

Hi All ...
I am looking for simple T-SQL syntax for using ExportData method with
Bulkcopy object to export one table in tab delimited, text file format to
C:\TableName.txt. First row of text file should be column headers.
Anybody know offhand?
[TableName].ExportData ?
Thanks for your help ...When you refer to the BulkCopy object and ExportData method, you must be
speaking of Data Management Objects (DMO), which isn't easily called from
T-SQL. The best and most prevalent method of exporting data to a text file
would be to create a DTS package.
"bill_morgan" <billmorgan@.discussions.microsoft.com> wrote in message
news:FD5558FE-CB29-44A6-ADA8-24DD306527CE@.microsoft.com...
> Hi All ...
> I am looking for simple T-SQL syntax for using ExportData method with
> Bulkcopy object to export one table in tab delimited, text file format to
> C:\TableName.txt. First row of text file should be column headers.
> Anybody know offhand?
> [TableName].ExportData ?
> Thanks for your help ...
>
>|||I like to use T-sql script wherever possible, but sounds like this is one of
those times when it's best not to. Thanks for your help.
"JT" wrote:

> When you refer to the BulkCopy object and ExportData method, you must be
> speaking of Data Management Objects (DMO), which isn't easily called from
> T-SQL. The best and most prevalent method of exporting data to a text file
> would be to create a DTS package.
> "bill_morgan" <billmorgan@.discussions.microsoft.com> wrote in message
> news:FD5558FE-CB29-44A6-ADA8-24DD306527CE@.microsoft.com...
>
>

Friday, March 9, 2012

Export to PDF in a new window using web service render method

We have an order screen which we would like to be visible at all times, and a
report based off some of the information on that screen. Is there any way to
keep this window open and open the report in a new window? Right now the
button used to launch the report is a server control button. This is what I
use now to open in the same window:
'setup parameters here...
result = rs.Render(reportPath, format, historyID, devInfo, parameters,
credentials, showHideToggle, encoding, mimeType, reportHistoryParameters,
warnings, streamIDs)
sh.SessionId = rs.SessionHeaderValue.SessionId
With Response
.ClearContent()
.AppendHeader("content-length", result.Length.ToString())
.ContentType = "application/pdf"
.BinaryWrite(result)
.Flush()
.Close()
End With
I did some reading and tried using window.open but to no avail. Any
suggestions?Does this help?
For the following you need SP1 or greater installed.
= "javascript:void(window.open('http://www.google.com','_blank'))"
Wayne Snyder MCDBA, SQL Server MVP
Mariner, Charlotte, NC
(Please respond only to the newsgroup.)
I support the Professional Association for SQL Server ( PASS) and it's
community of SQL Professionals.
"Treviathon" <Treviathon@.discussions.microsoft.com> wrote in message
news:454A2439-8071-48A2-9476-DA631E985D6C@.microsoft.com...
> We have an order screen which we would like to be visible at all times,
and a
> report based off some of the information on that screen. Is there any way
to
> keep this window open and open the report in a new window? Right now the
> button used to launch the report is a server control button. This is what
I
> use now to open in the same window:
> 'setup parameters here...
> result = rs.Render(reportPath, format, historyID, devInfo, parameters,
> credentials, showHideToggle, encoding, mimeType, reportHistoryParameters,
> warnings, streamIDs)
> sh.SessionId = rs.SessionHeaderValue.SessionId
> With Response
> .ClearContent()
> .AppendHeader("content-length", result.Length.ToString())
> .ContentType = "application/pdf"
> .BinaryWrite(result)
> .Flush()
> .Close()
> End With
> I did some reading and tried using window.open but to no avail. Any
> suggestions?|||I'm trying the same thing.
I've tried your solution, and it doesn't work for me. Maybe I'm
misunderstanding?
I've put the snippet of javascript on the OnClickevent of my asp.net
pushbutton, and I can't compile the project. Can you give me a fuller
sample?
Thx

Wednesday, February 15, 2012

Export report to PDF programmatically (forms authentication)

I use ReportExecutionService class to export a SQL reporting services report to a PDF file. It seems not work, and failed at method “LoadReport”. The error message said: Object moved to <ReportServer Login Page>.

I think, it’s an authentication problem. The report server is set to form authentication, and I wrote a custom security DLL, and share the auth cookie with ASP.NET Web application. It works fine with ReportViewer.

I set ReportExecutionService.Credentials = System.Net.CredentialCache.DefaultCredentials. It looks like my network login windows account (MyDomainName\MyUserName), and of course it is failed. I read the ReportExecutionService class members, and can not find way to pass auth cookie, or some kind of forms authentication object into ReportExecutionService class.

Does anyone render report into PDF (HTML) file successfully by ASP.NET code for forms authentication?

I search the sample code over internet. The sample code only uses CredentialCache.DefaultCredentials, and it looks a windows authentication credential. Am I wrong?

Thanks for any suggestion and advice.

ShawTry setting impersonation to true in the web.config file.