Showing posts with label page. Show all posts
Showing posts with label page. Show all posts

Monday, March 19, 2012

Create reports in ASP format?

We use an internal tool that can display ASP pages. I would like to use SQL Reporting Services to create reports in ASP format. The ASP page will access the database to get data. Is this possible possible with Reporting Services?

Ric

Hmmm... from what I understand, an ASP page is very similar to an ASPX page (created by Visual Studio). Possibly you could embed a report viewer in your ASP page. However, I'm not really sure that this is possible.

I'm not so sure that you want to create reports in ASP format -- that isn't possible. I think you are saying you want to display reports within an ASP page.

|||Active Server Pages and C# are completely different. Similar only because they are both programming languages. ASP was never meant to work with SQL Reporting Services. ASP works through ODBC and other interfaces and can connect to SQL databases and display the data onto web pages that have been setup using HTML tables using such things as the for loop etc..., but was never meant to work in this enviorment.

Wednesday, March 7, 2012

Create Multi-server environment in the SQL 2005- need HELP

I tried to setup a master-target server for the multi-server
environment
I tried the step in the microsoft support page already, but I keep
getting stucked with Create master wizard's third and fourth step.
This is my scenario: I have computer A and B connected in my network.
All of the SQLServer and SQL Agent in both machines uses a windows
authentications.
Both machines can communicate well already.
So, in the Create Master Server Wizard at Computer A I do:
-> Next
-> Next (leave all values blank for the email, pager and net send
address)
-> Add Connection to Computer B with windows authentication
-> Check compatibility success (meaning that the login successful as
well), then close
-> I check the "create a new login if necessary and assign it rights to
the MSX", then next
-> Finish
In the 3rd step: "Ensure the agent startup account for 'Computer B' has
rights to login as a target server", I got this error message:
===================================================================================== TITLE: Microsoft.SqlServer.Smo
--
Create failed for Login '.\TargetAdmin'.
For help, click:
http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+Login&LinkId=20476
--
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or
batch. (Microsoft.SqlServer.ConnectionInfo)
--
Windows NT user or group '.\TargetAdmin' not found. Check the name
again. (Microsoft SQL Server, Error: 15401)
For help, click:
http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&EvtSrc=MSSQLServer&EvtID=15401&LinkId=20476
--
BUTTONS:
OK
--
==========================================================================================================
In the fourth step: "Enlist 'Computer B' to 'Computer A', I got this
error message:
========================================================================================================== TITLE: Microsoft.SqlServer.Smo
--
MSX enlist failed for JobServer '155.64.154.169'.
For help, click:
http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=MSX+enlist+JobServer&LinkId=20476
--
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or
batch. (Microsoft.SqlServer.ConnectionInfo)
--
The enlist operation failed (reason: SQLServerAgent Error: Unable to
connect to MSX 'SYMANTEC-6VBB5C'.) (Microsoft SQL Server, Error: 22026)
For help, click:
http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&EvtSrc=MSSQLServer&EvtID=22026&LinkId=20476
--
BUTTONS:
OK
--
==========================================================================================================
Need help deperately >,<Are your servers domain members?
It looks like you have a problem with login from one server to other.
Accordint to the error messge '.\TargetAdmin' is a local account.
"ipramono@.gmail.com" wrote:
> I tried to setup a master-target server for the multi-server
> environment
> I tried the step in the microsoft support page already, but I keep
> getting stucked with Create master wizard's third and fourth step.
> This is my scenario: I have computer A and B connected in my network.
> All of the SQLServer and SQL Agent in both machines uses a windows
> authentications.
> Both machines can communicate well already.
> So, in the Create Master Server Wizard at Computer A I do:
> -> Next
> -> Next (leave all values blank for the email, pager and net send
> address)
> -> Add Connection to Computer B with windows authentication
> -> Check compatibility success (meaning that the login successful as
> well), then close
> -> I check the "create a new login if necessary and assign it rights to
> the MSX", then next
> -> Finish
> In the 3rd step: "Ensure the agent startup account for 'Computer B' has
> rights to login as a target server", I got this error message:
> =====================================================================================> TITLE: Microsoft.SqlServer.Smo
> --
> Create failed for Login '.\TargetAdmin'.
> For help, click:
> http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+Login&LinkId=20476
> --
> ADDITIONAL INFORMATION:
> An exception occurred while executing a Transact-SQL statement or
> batch. (Microsoft.SqlServer.ConnectionInfo)
> --
> Windows NT user or group '.\TargetAdmin' not found. Check the name
> again. (Microsoft SQL Server, Error: 15401)
> For help, click:
> http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&EvtSrc=MSSQLServer&EvtID=15401&LinkId=20476
> --
> BUTTONS:
> OK
> --
> ==========================================================================================================> In the fourth step: "Enlist 'Computer B' to 'Computer A', I got this
> error message:
> ==========================================================================================================> TITLE: Microsoft.SqlServer.Smo
> --
> MSX enlist failed for JobServer '155.64.154.169'.
> For help, click:
> http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=MSX+enlist+JobServer&LinkId=20476
> --
> ADDITIONAL INFORMATION:
> An exception occurred while executing a Transact-SQL statement or
> batch. (Microsoft.SqlServer.ConnectionInfo)
> --
> The enlist operation failed (reason: SQLServerAgent Error: Unable to
> connect to MSX 'SYMANTEC-6VBB5C'.) (Microsoft SQL Server, Error: 22026)
> For help, click:
> http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&EvtSrc=MSSQLServer&EvtID=22026&LinkId=20476
> --
> BUTTONS:
> OK
> --
> ==========================================================================================================> Need help deperately >,<
>

Create Multi-server environment in the SQL 2005- need HELP

I tried to setup a master-target server for the multi-server
environment
I tried the step in the microsoft support page already, but I keep
getting stucked with Create master wizard's third and fourth step.
This is my scenario: I have computer A and B connected in my network.
All of the SQLServer and SQL Agent in both machines uses a windows
authentications.
Both machines can communicate well already.
So, in the Create Master Server Wizard at Computer A I do:
-> Next
-> Next (leave all values blank for the email, pager and net send
address)
-> Add Connection to Computer B with windows authentication
-> Check compatibility success (meaning that the login successful as
well), then close
-> I check the "create a new login if necessary and assign it rights to
the MSX", then next
-> Finish
In the 3rd step: "Ensure the agent startup account for 'Computer B' has
rights to login as a target server", I got this error message:
========================================
====================================
=========
TITLE: Microsoft.SqlServer.Smo
--
Create failed for Login '.\TargetAdmin'.
For help, click:
http://go.microsoft.com/fwlink?Prod...in&LinkId=20476
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or
batch. (Microsoft.SqlServer.ConnectionInfo)
Windows NT user or group '.\TargetAdmin' not found. Check the name
again. (Microsoft SQL Server, Error: 15401)
For help, click:
http://go.microsoft.com/fwlink?Prod...01&LinkId=20476
BUTTONS:
OK
--
========================================
====================================
==============================
In the fourth step: "Enlist 'Computer B' to 'Computer A', I got this
error message:
========================================
====================================
==============================
TITLE: Microsoft.SqlServer.Smo
--
MSX enlist failed for JobServer '155.64.154.169'.
For help, click:
http://go.microsoft.com/fwlink?Prod...er&LinkId=20476
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or
batch. (Microsoft.SqlServer.ConnectionInfo)
The enlist operation failed (reason: SQLServerAgent Error: Unable to
connect to MSX 'SYMANTEC-6VBB5C'.) (Microsoft SQL Server, Error: 22026)
For help, click:
http://go.microsoft.com/fwlink?Prod...26&LinkId=20476
BUTTONS:
OK
--
========================================
====================================
==============================
Need help deperately >,<Are your servers domain members?
It looks like you have a problem with login from one server to other.
Accordint to the error messge '.\TargetAdmin' is a local account.
"ipramono@.gmail.com" wrote:

> I tried to setup a master-target server for the multi-server
> environment
> I tried the step in the microsoft support page already, but I keep
> getting stucked with Create master wizard's third and fourth step.
> This is my scenario: I have computer A and B connected in my network.
> All of the SQLServer and SQL Agent in both machines uses a windows
> authentications.
> Both machines can communicate well already.
> So, in the Create Master Server Wizard at Computer A I do:
> -> Next
> -> Next (leave all values blank for the email, pager and net send
> address)
> -> Add Connection to Computer B with windows authentication
> -> Check compatibility success (meaning that the login successful as
> well), then close
> -> I check the "create a new login if necessary and assign it rights to
> the MSX", then next
> -> Finish
> In the 3rd step: "Ensure the agent startup account for 'Computer B' has
> rights to login as a target server", I got this error message:
> ========================================
==================================
===========
> TITLE: Microsoft.SqlServer.Smo
> --
> Create failed for Login '.\TargetAdmin'.
> For help, click:
> http://go.microsoft.com/fwlink?Prod...in&LinkId=20476
> --
> ADDITIONAL INFORMATION:
> An exception occurred while executing a Transact-SQL statement or
> batch. (Microsoft.SqlServer.ConnectionInfo)
> --
> Windows NT user or group '.\TargetAdmin' not found. Check the name
> again. (Microsoft SQL Server, Error: 15401)
> For help, click:
> http://go.microsoft.com/fwlink?Prod...01&LinkId=20476
> --
> BUTTONS:
> OK
> --
> ========================================
==================================
================================
> In the fourth step: "Enlist 'Computer B' to 'Computer A', I got this
> error message:
> ========================================
==================================
================================
> TITLE: Microsoft.SqlServer.Smo
> --
> MSX enlist failed for JobServer '155.64.154.169'.
> For help, click:
> http://go.microsoft.com/fwlink?Prod...er&LinkId=20476
> --
> ADDITIONAL INFORMATION:
> An exception occurred while executing a Transact-SQL statement or
> batch. (Microsoft.SqlServer.ConnectionInfo)
> --
> The enlist operation failed (reason: SQLServerAgent Error: Unable to
> connect to MSX 'SYMANTEC-6VBB5C'.) (Microsoft SQL Server, Error: 22026)
> For help, click:
> http://go.microsoft.com/fwlink?Prod...26&LinkId=20476
> --
> BUTTONS:
> OK
> --
> ========================================
==================================
================================
> Need help deperately >,<
>

Friday, February 24, 2012

Create Excel Output

I successfully use the code below to output a report to a web page or to a
PDF file (which opens in Acrobat Reader) but when I try to create an Excel
file, it looks like the result is the binary for an Excel file being
displayed in a HTML page. Where can I get informarion on how to modify the
render method settings to create an Excel file and open it in Excel? I've
tried Googling variations of "render" but am not finding what I need.
Wayne
============================ Dim strRenderType As String = Session("RenderType")
Dim rs1 As New myAccount.rs.ReportingService
rs1.Credentials = New System.Net.NetworkCredential("myRSServer", "myPW", "")
Dim results As Byte(), image As Byte()
Dim streamids As String(), streamid As String
' Render the report to HTML4.0
results = rs1.Render(Session("ReportPath"), strRenderType, _
Nothing,
"<DeviceInfo><StreamRoot>/WebApplication1/</StreamRoot></DeviceInfo>",
Nothing, _
Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, streamids)
Response.BinaryWrite(results)You have to set the content-disposition header for your response to attachment.
Thanks
Tudor
"Wayne Wengert" wrote:
> I successfully use the code below to output a report to a web page or to a
> PDF file (which opens in Acrobat Reader) but when I try to create an Excel
> file, it looks like the result is the binary for an Excel file being
> displayed in a HTML page. Where can I get informarion on how to modify the
> render method settings to create an Excel file and open it in Excel? I've
> tried Googling variations of "render" but am not finding what I need.
> Wayne
> ============================> Dim strRenderType As String = Session("RenderType")
> Dim rs1 As New myAccount.rs.ReportingService
> rs1.Credentials = New System.Net.NetworkCredential("myRSServer", "myPW", "")
> Dim results As Byte(), image As Byte()
> Dim streamids As String(), streamid As String
> ' Render the report to HTML4.0
> results = rs1.Render(Session("ReportPath"), strRenderType, _
> Nothing,
> "<DeviceInfo><StreamRoot>/WebApplication1/</StreamRoot></DeviceInfo>",
> Nothing, _
> Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, streamids)
> Response.BinaryWrite(results)
>
>|||Tudor;
Thanks for the response but I am not familiar with the content-disposition
header. Where/how do I set that?
Wayne
"Tudor Trufinescu (MSFT)" <TudorTrufinescuMSFT@.discussions.microsoft.com>
wrote in message news:6606291C-832F-43A5-9D2F-1137DD2CEEEA@.microsoft.com...
> You have to set the content-disposition header for your response to
> attachment.
> Thanks
> Tudor
> "Wayne Wengert" wrote:
>> I successfully use the code below to output a report to a web page or to
>> a
>> PDF file (which opens in Acrobat Reader) but when I try to create an
>> Excel
>> file, it looks like the result is the binary for an Excel file being
>> displayed in a HTML page. Where can I get informarion on how to modify
>> the
>> render method settings to create an Excel file and open it in Excel? I've
>> tried Googling variations of "render" but am not finding what I need.
>> Wayne
>> ============================>> Dim strRenderType As String = Session("RenderType")
>> Dim rs1 As New myAccount.rs.ReportingService
>> rs1.Credentials = New System.Net.NetworkCredential("myRSServer", "myPW",
>> "")
>> Dim results As Byte(), image As Byte()
>> Dim streamids As String(), streamid As String
>> ' Render the report to HTML4.0
>> results = rs1.Render(Session("ReportPath"), strRenderType, _
>> Nothing,
>> "<DeviceInfo><StreamRoot>/WebApplication1/</StreamRoot></DeviceInfo>",
>> Nothing, _
>> Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, streamids)
>> Response.BinaryWrite(results)
>>|||Tudor;
I did some Googling and found information about that header. Thanks again
for the pointer.
Wayne
"Wayne Wengert" <wayneSKIPSPAM@.wengert.org> wrote in message
news:O$%23BJMS4FHA.3460@.TK2MSFTNGP12.phx.gbl...
> Tudor;
> Thanks for the response but I am not familiar with the content-disposition
> header. Where/how do I set that?
> Wayne
> "Tudor Trufinescu (MSFT)" <TudorTrufinescuMSFT@.discussions.microsoft.com>
> wrote in message
> news:6606291C-832F-43A5-9D2F-1137DD2CEEEA@.microsoft.com...
>> You have to set the content-disposition header for your response to
>> attachment.
>> Thanks
>> Tudor
>> "Wayne Wengert" wrote:
>> I successfully use the code below to output a report to a web page or to
>> a
>> PDF file (which opens in Acrobat Reader) but when I try to create an
>> Excel
>> file, it looks like the result is the binary for an Excel file being
>> displayed in a HTML page. Where can I get informarion on how to modify
>> the
>> render method settings to create an Excel file and open it in Excel?
>> I've
>> tried Googling variations of "render" but am not finding what I need.
>> Wayne
>> ============================>> Dim strRenderType As String = Session("RenderType")
>> Dim rs1 As New myAccount.rs.ReportingService
>> rs1.Credentials = New System.Net.NetworkCredential("myRSServer", "myPW",
>> "")
>> Dim results As Byte(), image As Byte()
>> Dim streamids As String(), streamid As String
>> ' Render the report to HTML4.0
>> results = rs1.Render(Session("ReportPath"), strRenderType, _
>> Nothing,
>> "<DeviceInfo><StreamRoot>/WebApplication1/</StreamRoot></DeviceInfo>",
>> Nothing, _
>> Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, streamids)
>> Response.BinaryWrite(results)
>>
>