To allow SQL Server Agent to trigger when a report is executed, we need to provide a set of report group types.



Similar documents
Tech Note 743 Configuring Reporting Services 2008 Configuration for a New Host Name in Windows 2008 R2

This tech note will explain how to use the following parameters in Configurator General Parameters.

Tech Note 751 Installing InBatch Report Contents for Wonderware Information Server (WIS)

Tech Note 338 How to Change the ActiveFactory Reporting Website Default Install Location

Tech Note 663 HMI Reports: Creating Alarm Database (WWALMDB) Reports

Tech Note 920 Resolving Disabled ActiveFactory Reporting Website for Wonderware System Platform R2

Tech Note 1010 SQL Server Authentication and ArchestrA Network Account Restrictions When Installing Wonderware Historian

Introduction. Configuration: Entity and OCO Modeling. Application Version: OCO General Configuration

Tech Note 847 Installing Wonderware Information Server (WIS) on the Windows Server Window 7 64 and 32-bit Operating System

Enabling Cross-Machine Distributed Transactions (via MSDTC)

Tech Note 882 Configuring Time Synchronization for Historian Server Using Net Time and Windows Task Scheduler

1. Under Application Objects, open the $Tank object and then open the $TankDisplay as shown in Figure 1 (below).

This Tech Note describes working with Microsoft Reporting Services in order to publish InBatch Reports to Wonderware Information Server.

Tech Note 612 Upgrading DLL Version Mismatches Between CBM Solution and System Platform

Migrating QI 8.0 Admin and Process Databases from Microsoft Access to Microsoft SQL Server

Introduction. Notes. Important Considerations. Application Versions. Assumptions. 8/22/13 Setting Up Historian Servers for Tier-2 Summary Replication

Tech Note 782 Installing Remote Desktop Services on Windows 2008 Server R2 for Wonderware Products

Note: Not all messages in the log are indicative of a problem. Contact Technical Support if questions arise.

Instead, use the following steps to update system metadata that is stored in sys.servers and reported by the system function

Tech Note 882 Configuring Time Synchronization for Historian Server Using Net Time and Windows Task Scheduler

Tech Note 551 Configuring SQLMail or Database Mail for the Historian Event

Communication to End Device Going In and Out of Slow Poll Mode

8/22/13 Configuring Windows SharePoint Services for PEM v1.0 to Work with SuiteVoyager v2.6

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

This Tech Note provides detailed guidelines and options for defragmenting and maintaining your production databases.

Tech Note 868 Troubleshooting Wonderware Software Resource Issues with Performance Monitor

Introduction. Application Versions. Installing Virtual SMTP Server. Tech Note 692 Using Virtual SMTP Server for SCADAlarm Notifications

Introduction. Symbol Script Timeout Setting. Sample MES Custom Code in Symbol Script. Application Versions. Sample Code

Introduction. Application Versions. Assumptions. Delete $$ExportTempFolders. Tech Note 930 Wonderware System Platform Clean-up Guide

Tech Note 957 Creating Custom Password Entry on Intermec-Supported Handhelds

Tech Note 400 Configuring Remote Connections for Windows 2000/2003/XP

Tech Note 912 Using Alternate TCP Port Numbers with Modbus Ethernet DAServer

Introduction. Tech Note 884 Setting Up Historian Servers for Tier-2 Summary Replication

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

Introduction. Back Up the Runtime Database. Application Versions

How To Migrate Qi Analyst To A New Database On A Microsoft Access (Windows) From A New Version Of Qi.Io To A Newer Version Of A New Qi 8.0 (Windows 7.3

Tech Note 782 Installing Remote Desktop Services on Windows 2008 Server R2 for Wonderware Products

Introduction. Issues. Symptoms. Application Versions. Case 1: Deploy an ArchestrA Object - UDO4DevUsers_001_001 - Has Error Messages

How To Write A Summary On A Historyorian Server

Tech Note 1042 Solving Historian Memory Issue with SQL Server MemToLeave Configuration

Part I: Setting up Bristol Babcock's OPC Server

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

Implementing the system using these guidelines should improve your system performance for a large database while your database grows in size.

Introduction. Application Versions. Compatibility and System Requirements. Firewall and DCOM Settings

This Tech Note provides step-by-step procedures to install Microsoft SQL Server 2012 on a 32- or 64-bit Operating System.

Tech Note 1035 Moving the Historian Runtime Database to Another Machine Using SQL Server 2012

Note: This Tech Note was formerly titled Installing Microsoft SQL Server 2008 for Wonderware Historian v10.0.

Industrial Application Server Redundancy: Troubleshooting Guidelines

8/22/13 Configuring the SST5136SD PCI Card Using the New SSTDHP IO Server V8.1 or the DASDHPlus Server

Tech Note 905 Troubleshooting Wonderware Information Server (WIS) Part Six: ArchestrA Graphics No Live-Data

8/23/13 Configuring SIDirect DAServer to Communicate with S7 PLC Over TCP Connection

Tech Note 652 Changing an ArchestrA Symbol's Custom Property Expression or Reference in Runtime

Tech Note 813 Troubleshooting Wonderware Information Server (WIS) Part Four: Client License Release

Using Network Application Development (NAD) with InTouch

This Tech Note describes modem connections using DAServers and provides some guidelines on how to make the modem connection work.

Security Settings for Wonderware Products

Tech Note 128 Configuring InBatch For Standalone PCs With SQL Server and IndustrialSQL Server

Installing the TCP/IP Network Protocol

Wonderware Historian Client Installation Guide. Invensys Systems, Inc.

Automated backup. of the LumaSoft Gas database

Tech Note 53 Configuring the Siemens SINEC H1 CP1413 for Windows NT

8/23/13 Configuring the Wonderware SECS-II/GEM Host Creator (SERIAL-RS232)

ArchestrA Log Viewer User s Guide Invensys Systems, Inc.

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

8/23/13 Configuring the S7 Server for Windows NT 4.0 to Access S7-400 PLCs via the Siemens CP1613 Card for ISO (Industrial Ethernet)

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

Tech Note 213 Finding Memory Leaks in Windows 95/98/98SE Using System Monitor

Installing LearningBay Enterprise Part 2

SELF SERVICE RESET PASSWORD MANAGEMENT BACKUP GUIDE

Installing and configuring Microsoft Reporting Services

ARIS Education Package Process Design & Analysis Installation Guide. Version 7.2. Installation Guide

Click to begin. Maitre'D Full System Backup & Restore

Archive Add-in User Guide

How to Backup and FTP your SQL database using E2.

HELP DOCUMENTATION E-SSOM BACKUP AND RESTORE GUIDE

Technical Bulletin. SQL Express Backup Utility

HELP DOCUMENTATION E-SSOM BACKUP AND RESTORE GUIDE

Jolly Server Getting Started Guide

Using Microsoft Windows Authentication for Microsoft SQL Server Connections in Data Archive

Instructions. Introduction

Moving PCLaw Data to Another Location (For LexisNexis PCLaw TM version 8.20 and higher)

Introduction. There are several bits of information that must be moved:

Introduction. Key Benefits. Data Storage. Data Retrieval. TechTip: Wonderware Historian a Look at Different Data Retrieval Methods.

SQM. Maintaining Microsoft SQL for Broadcast Engineers. Training Course Outline

How to protect, restore and recover SQL 2005 and SQL 2008 Databases

Migrating helpdesk to a new server

Real-Time Analysis and Reporting Software for Production and Performance Management

How to schedule SQL Maintenance Plan

Feith Rules Engine Version 8.1 Install Guide

Lab 05: Deploying Microsoft Office Web Apps Server

Published. Technical Bulletin: Use and Configuration of Quanterix Database Backup Scripts 1. PURPOSE 2. REFERENCES 3.

WebSphere Business Monitor

Sage HRMS 2014 Sage Employee Self Service Tech Installation Guide for Windows 2003, 2008, and October 2013

Database Maintenance ZENworks Mobile Management 2.7.x August 2013

Using SQL Server 2008 Automated Backup

TSM Studio Server User Guide

Enabling Remote Management of SQL Server Integration Services

Setting up a Scheduled task to upload pupil records to ParentPay

Dream Report Version 4.5

Administrator s Guide to deploying Engagement across multiple computers in a network using Microsoft Active Directory

Transcription:

Tech Note 573 Using SQL Server Agent to Run Scheduled Reports All Tech Notes, Tech Alerts and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information. Topic#: 002326 C reated: February 2009 Introduction This Tech Note provides an example of configuring SQL Server Agent to manage the execution of published reports for ActiveFactory. It also provides an example of configuring a custom event Archiving Rule and Scheduled Report Path for the SQL Server Agent. Application Versions Wonderware ActiveFactory 9.2 Wonderware Information Server (WIS) 3.0 Microsoft SQL Server 2005 Configure Event Group To allow SQL Server Agent to trigger when a report is executed, we need to provide a set of report group types. Scheduled Report paths and Archiving rules are configured in the Configuration.config file located at C:\Inetpub\wwwroot\AFWeb. 1. Backup the Configuration.Config file. 2. Open the Configuration.Config file with Notepad. 3. Use the Ctrl+F keys to find the WEEKLY element as it appears in Figure 1 (below). 4. Make a copy of the WEEKLY archival rule element. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 1/8

FIGURE 1: COPY THE WEEKLY ARCHIVAL RULE 5. Modify the name and description of the new weekly archival rule. In this example, it is called WEEKLYAgent. FIGURE 2: RENAME AFTER COPYING For example: <WEEKLYAgent Description="Rule that applies to all reports assigned to the WEEKLY schedule using sql server agent."> <DIRECTORYNAME> https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 2/8

<FORMATSTRING>MM (MMM)</FORMATSTRING> </DIRECTORYNAME> <FILENAME> <FORMATSTRING>'Week of' dd-mm-yyyy</formatstring> </FILENAME> <OLDERTHAN>365,0,0</OLDERTHAN> <!-- 365 = one year --> <KEEPCOUNT>520</KEEPCOUNT> <!-- 520 = ten years' worth of weekly reports --> </WEEKLYAgent> 5. Create a copy of the Example Report for WEEKLY and name it WEEKLYAgent. You will need this Report Folder Name later. FIGURE 3: WEEKLYAGENT REPORT ELEMENT For example: <WEEKLYAgent> <DIRECTORYNAME> <FORMATSTRING>'Weeks of 'MMM-yyyy</FORMATSTRING> </DIRECTORYNAME> <FILENAME> <FORMATSTRING>'Week of' dd-mm-yyyy</formatstring> </FILENAME> </WEEKLYAgent> 6. Create a copy of the WEEKLY Scheduled Report Path and modify the settings so it mimics the behavior of an Event report type. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 3/8

FIGURE 4: MODIFIED EVENT REPORT SETTINGS For example: <WEEKLYAgent> <FOLDERNAME>Weekly</FOLDERNAME> <TIMEINTERVAL>0,0,0</TIMEINTERVAL> <!-- Change time interval to Event settings --> <STARTTIME>-1,*,*,*</STARTTIME> <!-- -1 => this never fires on its own --> <DESCRIPTION>Every week (SQL Server Agent)</DESCRIPTION> </WEEKLYAgent> 7. Save the Configuration.Config file. Within 30 seconds, the aahistclientreportingservice rereads this file and identifies the new group. It is then accessible when publishing from ActiveFactory Workbook. If the new Group does not appear, you may have a error in the file. Look at the OS event viewer. Publish the Report 1. Create a new ActiveFactory Workbook report and publish it as a Dynamic report. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 4/8

FIGURE 5: PUBLISH A DYNAMIC REPORT 2. Select Report Type Scheduled. 3. In the Schedules list, select the new schedule that we created. FIGURE 6: SCHEDULED REPORT TYPE Make sure you remember/save the Report Name as you will need this later. 4. Click OK to publish the report. 5. Report information is stored in the Runtime database on the selected server. The table containing this report is aahistclientreport. If you forget the name of this report, you can view it in this table. It will be needed later. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 5/8

FIGURE 7: REPORT NAME IN AAHISTCLIENTREPORT TABLE Schedule Report with SQL Server Agent 1. Using Microsoft SQL Server Management Studio, create a new Job for SQL Server Agent. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 6/8

FIGURE 8: CREATE A NEW SQL SERVER AGENT JOB 2. Provide the General page information for this job. FIGURE 9: GENERAL JOB INFORMATION https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 7/8

3. Select the Steps page and create a new step. Provide the Transact SQL script below. Modify the ReportFolderName and ReportName with the names you have noted in previous steps. UPDATE aahistclientreport SET LastRun='1753-1-1', Published=0 FROM aahistclientreport r, aahistclientreportsfolder f WHERE r.name = 'Book1' AND r.reportfolderkey = f.reportfolderkey AND f.reportfoldername = 'WEEKLYAgent' AND r.reportsitekey = 1 4. Select the Schedules page and create a new schedule. In this example, we created a weekly scheduled report. You can create any schedule you like. Note: The query provided to trigger a report can also be used with the InSQL Event System. Click the following icon to view this file in.pdf format: C. Azer Tech Notes are published occasionally by Wonderware Technical Support. Publisher: Invensys Systems, Inc., 26561 Rancho Parkway South, Lake Forest, C A 92630. There is also technical information on our software products at Wonderware Technical Support. For technical support questions, send an e-mail to support@wonderware.com. Back to top 2013 Invensys Systems, Inc. All rights reserved. No part of the material protected by this copyright may be reproduced or utilized in any form or by any means, electronic or mechanical, including photocopying, recording, broadcasting, or by anyinformation storage and retrieval system, without permission in writing from Invensys Systems, Inc. Terms of Use. https://wdnresource.wonderware.com/support/kbcd/html/1/t002326.htm 8/8