本文介绍了SQL Server 2008R2 Reporting Services:数据驱动订阅的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我是Reporting Services的新手,我希望能够在创建记录时自动向客户发送电子邮件.
我已经能够配置报告服务器并发送包含报告的电子邮件:到目前为止一切顺利.

订阅后面的查询基于表中的某个标志"ReportSendByEmail".只能通过电子邮件发送该标志设置为0的记录的报告.
因此,我想通过添加发送报告后将位值更新为1的步骤来适应SQL Server作业.

奇怪的是,添加该步骤后,不再发送报告.
-步骤1(发送报告)配置为成功进行下一步"
-步骤2(更新标志)配置为退出作业报告成功"
但是,位标记已更新为1.

检查工作历史:没有提及任何错误,一切都应该没问题.
但是邮箱保持为空.仅当删除步骤2时,邮件才会回来(所有电子邮件地址均设置为我的本地地址).

知道这可能是什么原因吗?
也许是安全问题:
-第一步由用户"NT AUTHORITY \ NETWORK SERVICE"处理
-第二步由用户"sa"处理
两个用户都可以完全访问包含必需数据的数据库.

有任何想法吗?

Hi,

I''m new to Reporting Services and I want to be able to automatically send an email to a customer when a record is created.
I''ve been able to configure the report server and send the email containing the report: so far so good.

The query behind the subscription is based on a certain flag ''ReportSendByEmail'' in a table. Only reports with records with this flag set to 0 should be sent by email.
Therefore, I want to adapt the SQL Server Job by adding a step which updates the bit-value to 1 after the report has been sent.

Strangely enough, after adding that step, the report isn''t sent anymore.
- Step 1 (sending the report) is configured to ''go the next step on success''
- Step 2 (updating the flag) is configured to ''Quit the job reporting successs''
The bit-flag however is updated to 1.

Checking the job-history: No errors are mentioned, everything should be ok.
But the mailbox stays empty. Only when removing step 2, the mails are coming back in (all email-addresses are set to my local address).

Any idea what may be the cause of this ?
Maybe it''s a security issue:
- The first step is processed by user ''NT AUTHORITY\NETWORK SERVICE''
- The second step is processed by user ''sa''
Both users have full access to the database containing the necessary data.

Any ideas ?

推荐答案


这篇关于SQL Server 2008R2 Reporting Services:数据驱动订阅的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-22 06:47