Here are the workflows that emulate the GN3 reports system.
To try it, import into your database the following workflows:
cmd4 config -in ..\config\global\gn4\wf_GN3Report.xml -username xxxx -password yyyy
cmd4 config -in ..\config\global\gn4\wf_GN3ReportEdition.xml -username xxxx -password yyyy
where xxxx is the name of a GN4 user who can logon to system with sufficient permissions to perform this operation and yyyy is the password.
Note: the above connects to the default connection: should you want to specify the connection or server name, see cmd4 examples.
Note that the wf_GN3Report workflow calls wf_GN3ReportEdition.
The report data can be written into xml files or stored into the report database.
The wf_GN3Report.xml workflow needs the following parameters to generate the report:
•the edition ids ('Ids=' parameter). If missing, then a valid workstate name must be provided.
•the workstate name ('workstate' parameter). The workflow looks for the editions having the input workstate. It is ignored if the edition ids are provided.
•the path of the folder where creating the xml report files ('folderPath' parameter). If missing, then the report is generated into the database using the input ODBC connection string.
•the ODBC connection string ('ODBCString' parameter). It is the string containing the data needed to connect to the destination database. It is ignored if the destination folder path is provided.
Note the semicolon ';' characters into the connection string must be escaped with backslash '\'.
For example, to generate the report of the edition with id 1234 into the 'c:\temp' folder, you have to call the wf_GN3Report workflow with the following parameters:
And the resulting workflow log is something like this:
<INFO> Created 1 title in 'c:\temp\ReportTitles.xml' (1707).
<INFO> Created 8 security in 'c:\temp\ReportSecurity.xml' (2065,1609,1607,1606,5,4,3,2).
<INFO> Created 1 edition in 'c:\temp\ReportEditions.xml' (2083).
<INFO> Created 12 page in 'c:\temp\ReportPages.xml' (2110,2109,2108,2107,2106,2105,2104,2103,2102,2101,2100,2099).
<INFO> Created 12 pageLayer in 'c:\temp\ReportLayers.xml' (2098,2097,2096,2095,2094,2093,2092,2091,2090,2089,2088,2087).
<INFO> Created 2 article in 'c:\temp\ReportArticles.xml' (2171,2111).
<INFO> Created 3 txt in 'c:\temp\ReportTxts.xml' (2189,2174,2172).
<INFO> Created 3 txt in 'c:\temp\ReportTxts_00001.xml' (2192,2115,2113).
Another example: to generate the report of the editions having the 'Page Closed' workstate into the ReportDB database, you have to call the wf_Gn3Report workflow with the following parameters string:
Pars=workstate:Page Closed;ODBCString:Driver={SQL Server}\;Server=mySQLServer;Database=ReportDB\;uid=myDbUser\;pwd=myPassword;
Note that the reports system cannot overwrite the rows already existing in the target database.