简体   繁体   English

Reporting Services 订阅不允许修改收件人:字段

[英]Reporting Services Subscriptions won't allow modification of the To: Field

I have a little issue that is causing me a headache.我有一个让我头疼的小问题。 Our Report Server is SQL Ent 2008 on a Win 2008 server.我们的报表服务器是 SQL Ent 2008,在 Win 2008 服务器上。 When users that have Report Browser permissions try to set up a report subscription the To: field is grayed out and pre-populated with their username.当具有报表浏览器权限的用户尝试设置报表订阅时,收件人:字段会变灰并预先填充他们的用户名。 They cannot change this and it won't deliver to their email address which would be username@domain.com.他们无法更改此设置,也不会发送到他们的 email 地址,即 username@domain.com。 Any leads would be greatly appreciated.任何线索将不胜感激。

"Site Settings".."Configure item-level role definitions".."Browser" “网站设置”..“配置项目级角色定义”..“浏览器”

They can only "Manage individual subscriptions". 他们只能“管理个人订阅”。 SSRS won't allow the email address to be changed because they could put any stuff in there. SSRS不允许更改电子邮件地址,因为他们可以在其中放置任何内容。

In BOL, Managing Subscriptions ... and How to: Subscribe to a Report (Report Manager) , which leads to Configuring a Report Server for E-Mail Delivery . 在BOL, 管理订阅 ...以及如何:订阅报表(报表管理器) ,这将导致配置报表服务器以进行电子邮件传递 This says: 这说:

Configuration Options for Setting the To: Field in a Message 用于在消息中设置“收件人:”字段的配置选项

User-defined subscriptions that are created according to the permissions granted by the Manage individual subscriptions task contain a pre-set user name that is based on the domain user account. 根据管理个人订阅任务授予的权限创建的用户定义的订阅包含基于域用户帐户的预设用户名。 When the user creates the subscription, the recipient name in the To: field is self-addressed using the domain user account of the person creating the subscription. 当用户创建订阅时,“收件人:”字段中的收件人姓名将使用创建订阅的人员的域用户帐户进行自我寻址。

If you are using an SMTP server or forwarder that uses e-mail accounts that are different from the domain user account, the report delivery will fail when the SMTP server tries to deliver the report to that user. 如果您使用的SMTP服务器或转发器使用与域用户帐户不同的电子邮件帐户,则当SMTP服务器尝试将报告传递给该用户时,报告传递将失败。

To workaround this issue, you can modify configuration settings that allow users to enter a name in the To: field: 要解决此问题,您可以修改允许用户在“收件人:”字段中输入名称的配置设置:

  1. Open RSReportServer.config with a text editor. 使用文本编辑器打开RSReportServer.config。
  2. Set SendEmailToUserAlias to False. 将SendEmailToUserAlias设置为False。
  3. Set DefaultHostName to the Domain Name System (DNS) name or IP address of the SMTP server or forwarder. 将DefaultHostName设置为SMTP服务器或转发器的域名系统(DNS)名称或IP地址。
  4. Save the file. 保存文件。

I realize that this is on a 3 year old post (there was activity on it 5 months ago as of this posting though) but I found one other tid-bit that may be of use to others trying to get around this. 我意识到这是一个3岁的帖子(虽然在5个月前有这个帖子的活动)但是我发现另外一个tid-bit可能对其他人试图解决这个问题。

As part of the configuration file RSReportServer.config as mentioned in above answers found at installdir \\Reporting Services\\ReportServer\\ there is a section of the file that you can add your domain name to that works in conjunction with the users alias. 作为配置文件RSReportServer.config的一部分,如在installdir \\ Reporting Services \\ ReportServer \\中找到的上述答案中所述,您可以将文件的一部分添加到与用户别名一起使用的域名。

The tag to edit is DefaultHostName as stated in Microsofts documentation this value works with the SendEmailToUserAlias tag when it's set to true. 要编辑的标记是DefaultHostName,如微软文档中所述,当设置为true时,此值与SendEmailToUserAlias标记一起使用。

The end user still has a grayed out To: field that shows their AD user alias, however when they setup a subscription to email a report, at execution time the SMTP server appends the specified domain (from the DefaultHostName tag) to the alias. 最终用户仍有灰色的To:字段,显示其AD用户别名,但是当他们设置通过电子邮件发送报告的订阅时,SMTP服务器会在执行时将指定的域(从DefaultHostName标记)附加到别名。

I didn't want to go with the work-a-round specified in the previous answer as I did not want end users to be able to specify any email address. 我不想使用前一个答案中指定的工作轮次,因为我不希望最终用户能够指定任何电子邮件地址。

This worked for me in SSRS for SQL 2008 R2. 这在SSRS for SQL 2008 R2中适用于我。 Documentation from Microsoft here (http://msdn.microsoft.com/en-us/library/ms157273.aspx#bkmk_email_extension) 来自Microsoft的文档(http://msdn.microsoft.com/en-us/library/ms157273.aspx#bkmk_email_extension)

NB make sure you turn of the reporting services process before changing the file, after making and saving the changes, start the process back up. 注意:确保在更改文件之前关闭报告服务进程,在进行并保存更改后,请重新启动该进程。

I added to gbn's version of the solution. 我添加了gbn的解决方案版本。

1.Open RSReportServer.config with a text editor. 1.使用文本编辑器打开RSReportServer.config。

2.Set SendEmailToUserAlias to True. 2.将SendEmailToUserAlias设置为True。 (So the To: is not blank) (所以To:不是空白的)

3.Set DefaultHostName to the Domain Name System (DNS) name or IP address of the SMTP server or forwarder. 3.将DefaultHostName设置为SMTP服务器或转发器的域名系统(DNS)名称或IP地址。

4.Save the file. 4.保存文件。

This version will show your alias in the To: section and the email will go through now. 此版本将在“收件人:”部分显示您的别名,电子邮件将立即显示。

This works fine. 这很好用。

Just to let you know the file is in the following location (save you looking for it). 只是为了让您知道该文件位于以下位置(除了您寻找它)。 RSReportServer.config is located in the %Program Files%\\Microsoft SQL Server\\MSSQL.n\\Reporting Services\\ReportServer folder RSReportServer.config位于%Program Files%\\Microsoft SQL Server\\MSSQL.n\\Reporting Services\\ReportServer文件夹中

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM