How to determine the version of SQL Server on a report server

All of our production instances of Reporting Services are divided into web server components and report database components.

I know that you can detect an instance of SQL Server on a database server with the following TSQL:

SELECT SERVERPROPERTY('productversion'), SERVERPROPERTY ('productlevel'),
SERVERPROPERTY ('edition')

However, in our case, the report servers do not have the database server components installed. So, how to determine which service pack is installed in this situation?

+3
source share
3 answers

In manual mode or using web scraping, select

http://reportServerName/ReportServer 

and the version number is at the bottom of the page.

Or programmatically:

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;

class Sample
{
    static void Main(string[] args)
    {
        // Create proxy object and set service 
        // credentials to integrated
        ReportingService2006 rs = new ReportingService2006();
        rs.Url = "http://<Server Name>/_vti_bin/ReportServer/" +
            "ReportService2006.asmx";
        rs.Credentials = 
            System.Net.CredentialCache.DefaultCredentials;

        try
        {
            // Set the server info header 
            rs.ServerInfoHeaderValue = new ServerInfoHeader();

            // Make a call to the Web service
            CatalogItem[] items = rs.ListChildren("/");

            // Output the server version and edition to the console
            Console.WriteLine("Server version: {0}",
               rs.ServerInfoHeaderValue.ReportServerVersionNumber);
            Console.WriteLine("Server edition: {0}",
               rs.ServerInfoHeaderValue.ReportServerEdition);
        }

        catch (Exception e)
        {
            Console.WriteLine(e.Message);
        }
    }
}
+7
source

In the browser, go to

http://<reportserverName>/reportserver

Look at the bottom of the page.

+4

SQL Server.

+1

Source: https://habr.com/ru/post/1704439/


All Articles