Upload
santhoshi-mudunuri
View
230
Download
0
Tags:
Embed Size (px)
DESCRIPTION
LiveReports are powerful tools that allow direct access to the RDBMS underlying Livelink. To that end, they contain an SQL statement. You can have LiveReports return statistical information about the database contents (such as a pie chart showing the proportion of items owned by each user), or change the database contents (for example, re-assign all tasks of a user who left the organization).
Citation preview
25
Chapter Three
LIVEREPORTS
LiveReports are powerful tools that allow direct access to the RDBMS underlyingLivelink. To that end, they contain an SQL statement. You can have LiveReports returnstatistical information about the database contents (such as a pie chart showing theproportion of items owned by each user), or change the database contents (for example,re-assign all tasks of a user who left the organization). Due to this potential, carefulconsideration is necessary when allowing users to create LiveReports. On the other hand,you may want to grant users permission to run certain LiveReports, for example to list allLivelink items they own or have checked out. Granted permission, users can runLiveReports from the Status tab of their Personal or a Project Workspace.
This chapter covers the following topics:
Installing and Uninstalling the LiveReports Module on page 26
LiveReports Administration on page 27
Who Can Use LiveReports? on page 33
Examples: Creating LiveReports on page 33
Installing and Uninstalling the LiveReports Module
26
Livelink Forms and LiveReports Administrators Guide
Installing and Uninstalling the LiveReports Module
Livelinks modular structure allows you to include, exclude, or upgrade LiveReports foryour particular system.
The LiveReports module is automatically installed when you install Livelink.
Refer to the appropriate sections of the Installing, Uninstalling, and Upgrading Moduleschapter of the Livelink Installation Guide for information about installing, uninstalling, orupgrading the LiveReports module.
LiveReports Administration
LiveReports
27
LiveReports Administration
Most tasks ensuring that LiveReports work smoothly in your system are done from theLivelink Intranet Administration page. For information about Accessing the LivelinkIntranet Administration page, see the corresponding section of the Introduction to theLivelink Administrators Guide.
The following sections describe how the links on the Livelink Intranet Administrationpage allow you to:
Browse the LiveReports Volume
Export LiveReports
Import LiveReports
Specifying Valid Object Input Parameters is the only LiveReports-related administrativetask that requires editing the opentext.ini file; see page 32.
LiveReports Administration
28
Livelink Forms and LiveReports Administrators Guide
The LiveReports Volume
This system folder initially contains a set of LiveReports provided by Open Text. You canmodify these reports to meet your users needs. New LiveReports may be added to theReports Volume either via the Add New Item menu, or by importing them from outsideyour Livelink system, as described in the Importing LiveReports section.
LiveReports may be stored anywhere in Livelink. However, only those in the ReportsVolume appear on the Personal Workspace Status pages of users who are granted Seepermission for them (see page 33 on LiveReport Permissions, and the online Help formore information).
To access the Reports Volume:
1.
Click
Browse the LiveReports Volume
on the Livelink Intranet Administration page.
The Reports Volume page appears:
2.
You can now work with the
Reports Volume
the same as with other Livelink folders, for
example create new LiveReports within, administer permissions for the volume, configure
the volume, and so on.
LiveReports Administration
LiveReports
29
Exporting LiveReports
You can export LiveReports from Livelink to a text file. They can later be imported again,into a different Livelink system if you like, as described in the Importing LiveReportssection on page 31.
To export one batch of LiveReports:
1.
Click
Export LiveReports
on the Livelink Intranet Administration page.
The Export LiveReport page appears, displaying a check list of all existing LiveReports:
2.
Click the check box(es) corresponding to the LiveReport(s) you want to export into one
file.
LiveReports Administration
30
Livelink Forms and LiveReports Administrators Guide
3.
Click the
Export
button or the
Export and Delete
button, depending on whether you want
to keep the copy of the selected LiveReport(s) on your current Livelink system or not,
respectively.
A File Download dialog box opens.
4.
Browse to the network location where you would like to store the exported LiveReports
file. Enter a Filename with a
.txt
extension and click
Save
.
5.
Use your browsers
Back
button to return to the Livelink Intranet Administration page.
LiveReports Administration
LiveReports
31
Importing LiveReports
Instead of creating LiveReports from scratch within your system, you can import reportsthat were exported earlier from Livelink (see Exporting LiveReports on page 29). This addsgreat flexibility, as it allows your LiveReports to be generated on different Livelinksystems, for example, at partner organizations, or Open Text.
To import LiveReports:
1.
Click
Import LiveReports
on the Livelink Intranet Administration page.
The Import LiveReport page appears:
2.
Click the
Browse Livelink
button corresponding to the
Create In
field.
A separate window opens.
3.
Browse to the Livelink container to which you want to add the imported LiveReport(s),
and click its Select link.
The window closes, and the Import LiveReport page reappears with the selected locations
path name in the
Create In
field.
4.
Click the
Browse
button corresponding to the
Pick or Create an Export File
field.
A File Upload dialog box opens.
5.
Select a LiveReport file to upload from your computer or the network.
After closing the File Upload dialog box, the Import LiveReport page reappears with the
selected files path name in the
Pick or Create an Export File
field.
6.
Click the
Add Item
button.
The Livelink Intranet Administration page reappears.
LiveReports Administration
32
Livelink Forms and LiveReports Administrators Guide
Specifying Valid
Object
Input Parameters
Optionally, you can change the list from which users select a Livelink item type whenrunning an interactive LiveReport that uses an Input parameter of type Object (see alsoInteractive LiveReports with User Inputs on page 40). The default set of available item typesis explained below.
To specify which Object types will be available in the selection lists, use a text editor toedit the [report] section of the opentext.ini file located in the /installation_path/configdirectory of your primary Livelink host.
The default set of SubType codes shown above corresponds to the following item types:
Code
Item Type
299
LiveReport
215
Discussion
202
Project
206
Task
204
Task List
144
Document
0
Folder
140
URL
207
Channel
130
Topic
For a complete list of all SubType codes in your particular Livelink implementation, referto your Livelink RDBMS tables.
Who Can Use LiveReports?
LiveReports
33
Who Can Use LiveReports?
At least a basic knowledge of SQL and the Livelink Schema is necessary to editLiveReports effectively.
Depending on their SQL statements, LiveReports have potential for altering theinformation in the system database. To ensure the integrity of your Livelink Intranet,Open Text recommends limiting item creation privileges for LiveReports to a smallnumber of individuals, typically the Admin user. To protect your database, a user cannotmodify any LiveReport unless that user is given the LiveReports creation privilege as well.
The following sections discuss the user privilege to create LiveReports, and permissionsfor LiveReports, respectively.
LiveReports Creation Privilege
By default, the privilege to create LiveReports is restricted to the Admin user.
For full details on Administering Item Creation Privileges, refer to the correspondingsection of the Administering Livelink Items chapter in the Livelink Administrators Guide.
! Warning
A user who is allowed to modify or create LiveReports may include any
kind of SQL statement, not only
select
, but also
update
or
delete
. To
ensure the integrity of your Livelink system, Open Text recommends that
you leave the privilege to create LiveReports restricted to the Admin
user, or only extend it to a very small number of users who have
knowledge of both SQL and the Livelink Schema.
LiveReport Permissions
The permissions a user may be granted for a LiveReport are the same as for most otherLivelink items: See, See Contents, Modify, Edit Permissions, Edit Attributes, and Delete.
However:
Modify permission requires a user to have the LiveReport item creation privilege aswell, in order for it to become effective.
See Contents permission is necessary for users to be able to run the LiveReport.
Examples: Creating LiveReports
34
Livelink Forms and LiveReports Administrators Guide
Examples: Creating LiveReports
The following sections illustrate the creation of LiveReports using a specific scenario. Tosee more sample reports, make copies of some of the provided LiveReports (from theReports Volume) and use the Edit function to look at them and experiment. For morecomprehensive general information see the online Help.
! Note
You must have the LiveReports creation privilege in order to create,
copy, and edit LiveReports as suggested in the following examples.
As an example scenario, suppose you were interested in how many items are added eachday to your Livelink database. The following sections describe how to create LiveReportsto answer that question.
Examples: Creating LiveReports
LiveReports
35
Basic LiveReports
First, you can create a LiveReport that computes and lists the number of Livelink itemscreated each day:
1.
Select
LiveReport
from the
Add New Item
menu on the Home page of your Personal
Workspace.
The Add: LiveReport page appears.
2.
Make the following changes:
Change the default name in the
Name
field to:
New Items per Day
(Optional) In the Description text box, enter:
This LiveReport displays how many new Livelink items werecreated each day.
This information is only displayed on the LiveReport's General Info for page.
In the
Title
field, enter:
New Items per Day
(Optional) In the
Record Limit
field, change the maximum number of records to be
displayed. This depends on the age and size of your Livelink database, and on how
long a list you would like to see.
! Note
Carefully consider which record limit is safe, while still allowing the
LiveReport to fulfill its purpose. Too high a record limit may cause a
LiveReport to use up all resources in a large Livelink system. Too low a
limit may result in truncating the reported dataset before crucial records
are retrieved.
In the
SQL
text box, enter the following:
select count(*) "Number of Items", trunc(DTree.CreateDate)"Date" from DTree group by trunc(DTree.CreateDate) orderby trunc(DTree.CreateDate) desc
From the
Report Format
list, select
AutoLiveReport
, because the default
LiveReport
format only works for lists of Livelink items.
(Optional) Click the
Configure
button to customize the table layout in a separate
window. See the Tabular Formats online Help for more details.
Examples: Creating LiveReports
36
Livelink Forms and LiveReports Administrators Guide
Examples: Creating LiveReports
LiveReports
37
3.
Click the
Add Item
button.
Your Personal Workspace page reappears. If you did not change the location in the
Create In
field, the New Items per Day LiveReport is listed there with your other Livelink items:
Click New Items per Day to run the LiveReport, and examine the results. The result pageshould look similar to the following:
The next section discusses the use of parameters in LiveReports.
Examples: Creating LiveReports
38
Livelink Forms and LiveReports Administrators Guide
LiveReports with Parameters
Parameters are placeholders whose values are filled in at the time the LiveReport is run,for example the current date, the ID number of the user running the report, etc. Someparameter types function as acronyms for long lists. For example, the Report Field type isa shorthand notation for the list of columns minimally required by the LiveReport format.
To continue the example from the previous section, suppose you wanted a LiveReport todisplay how many items were created each day by the particular user who is running thereport. Simply incorporate the system parameter representing the current user as follows:
1.
Make a copy of your New Items per Day LiveReport from the previous section, and name
it:
My New Items per Day
2.
Click the
Edit
link of the My New Items per Day LiveReport.
The Edit: My New Items per Day page appears.
3.
Make the following changes:
Change the
title
to:
My New Items per Day
Change the
SQL
statement to:
select count(*) "Number of Items", trunc(DTree.CreateDate)"Date" from DTree where DTree.UserID=%1 group bytrunc(DTree.CreateDate) order by trunc(DTree.CreateDate)desc
From the
Param %1
list, select
UserID
.
Examples: Creating LiveReports
LiveReports
39
4.
Click the
Save and Execute
button.
A new page appears, showing the results of the updated LiveReport (that is, the number of
items you created on each day). At the same time, your changes are permanently stored with
the LiveReport.
Examples: Creating LiveReports
40
Livelink Forms and LiveReports Administrators Guide
Interactive LiveReports with User Inputs
The previous section discussed parameters that are automatically substituted by systemvalues at run time. User Input parameters are slightly differentthey allow the user tospecify interactively which value is to replace the parameter. When you run an interactiveLiveReport, Livelink displays a new page to prompt you for input. Depending on theInput parameter type, you click the provided browse link to make a selection, or enter avalue directly in the provided field.
To take the last example one step farther, suppose you wanted to be able to specify whosenew items to count, every time you run the LiveReport. This way, you could run the sameLiveReport, no matter whether you needed the number of User Xs new items per day, orthe number of User Ys new items. In the former case, you would run the LiveReport andselect X when prompted; in the latter case, you would run the same report but select Ywhen prompted.
Incorporate a User Input parameter of type User as follows:
1.
Make a copy of your My New Items per Day LiveReport from the previous section, and
name it:
[User]s New Items per Day
2.
Click the
Edit
link of the [User]s New Items per Day LiveReport.
The Edit: [User]s New Items per Day page appears.
3.
Make the following changes:
Change the
title
to:
Items created by the user with ID %1
From the first
Type
list in the
Inputs
section, select
User
.
Enter Whose items to count?
In the corresponding first
Prompt
field.
From the
Param %1
list, select
User Input 1
.
Examples: Creating LiveReports
LiveReports
41
Examples: Creating LiveReports
42
Livelink Forms and LiveReports Administrators Guide
4.
Click the
Save and Execute
button.
A new page appears, displaying the prompt
Whose items to count?,
and a
Browse for a User
link.
At the same time, your changes are permanently stored with the LiveReport.
5.
Click the
Browse for a User
link (whenever an interactive LiveReport provides a
browse
link,
you must use it to enter a value rather than typing the value).
A new window opens.
6.
If you know (part of) the last name of the user whose items you want to count, enter it in
the
Search
field.
In any case, click the
Find
button.
A list of available users appears.
7.
Click the
Select
link of the user of your choice.
The window closes, and the LiveReport page reappears with the name of the selected user in
the
Whose items to count?
field.
8.
Click the
Update
button to pass the user ID on to the LiveReport.
A new page appears, showing the results of your LiveReport, that is, the number of items the
selected user created on each day. Notice that the question mark for the parameter in the title
banner was replaced by the user ID number once that parameter value was specified:
Examples: Creating LiveReports
LiveReports
43
LiveReports with Sub-Reports
Sometimes additional questions arise when running a LiveReport and looking at itsresults. For example, when you see in the results returned by one of the earlier sampleLiveReports that a particularly high (or low) number of items was created on some days,you might wonder just which items those were. Livelink allows you to attach a sub-reportto any LiveReport, to answer such additional questions. If you attach a sub-report to aLiveReport, a Details link appears with each entry on the result page of the initial report.In the example, provided the sub-report is suitably defined, clicking the Details link of aparticular date in the initial table displays a list of all Livelink items created on that day.
In principle, any LiveReport may be attached as a sub-report, although somecoordination of parameters between the sub-report and its parent LiveReport isnecessary.
To illustrate the concept, a sample combination of a sub-report and a LiveReport using itis described in the remainder of this section.
Examples: Creating LiveReports
44
Livelink Forms and LiveReports Administrators Guide
A Sub-Report
In the first step, define and test the LiveReport that will become the sub-report. Itspurpose is to list all items created on a particular day by a particular user.
1.
Select
LiveReport
from the
Add New Item
menu on the Home page of your Personal
Workspace.
The Add: LiveReport page appears.
2.
Make the following changes:
Change the default name in the
Name
field to:
Items Created on Day X
(Optional) In the
Description
text box, enter:
This LiveReport lists all Livelink items that were createdon a particular day by a particular user.
This information is only displayed on the LiveReport's General Info for page.
In the
Title
field, enter:
Items created %1 by user ID %2
In the
Inputs
section:
Select
Date
from the first
Type
list, and enter Create Date?
as corresponding
Prompt.
Select
User
from the second
Type
list, and enter Whose Items?
as corresponding
Prompt.
In the
SQL
text box, enter the following:
select * from DTree where (trunc(DTree.CreateDate)=%1 andDTree.UserID=%2)
From the
Param %1
list, select
User Input 1
.
From the
Param %2
list, select
User Input 2
.
Examples: Creating LiveReports
LiveReports
45
Examples: Creating LiveReports
46
Livelink Forms and LiveReports Administrators Guide
3.
Click the
Add Item
button.
Your Personal Workspace page reappears. If you did not change the location in the
Create In
field, the Items Created on Day X LiveReport is listed there with your other Livelink items:
Click Items Created on Day X to test-run the LiveReport. Specify date and user whenprompted (enter the date according to the Date Input Format for your Livelink system),click the Update button, and examine the results.
The result page should look similar to the following:
Examples: Creating LiveReports
LiveReports
47
A
Parent
LiveReport
In the second step, you attach the sub-report to another LiveReport. To create a parentreport for the Items Created on Day X LiveReport:
1.
Make a copy of your New Items per Day LiveReport from the
LiveReports with Parameters
section, and name it:
My New Items per Day (Details)
2.
Click the
Edit
link of the My New Items per Day (Details) LiveReport.
The Edit: My New Items per Day (Details) page appears.
3.
Make the following changes:
For the
Click-thru Sub-Report
field, click the
Browse Livelink
button.
A new window opens.
Browse to the Items Created on Day X LiveReport, and click its
Select
link.
The window closes, and the Edit: My New Items per Day (Details) page reappears with
the path name of the sub-report in the
Click-thru Sub-Report
field.
In the
Sub-Report Param 1
field, enter Date
In the
Sub-Report Param 2
field, enter %1
Examples: Creating LiveReports
48
Livelink Forms and LiveReports Administrators Guide
Examples: Creating LiveReports
LiveReports
49
4.
Click the
Save and Execute
button.
A new page appears, showing the results of the updated LiveReport (that is, the number of
items you created on each day with
Details
links). At the same time, your changes are
permanently stored with the LiveReport. The result page should look similar to the following:
5.
Click one of the
Details
links.
A new page appears, showing the results of the attached sub-report. If at least one item was
created on the day whose
Details
link you clicked, these items should be listed similar to the
following:
6.
Your browsers
Back
button will take you back to the previous page, where you can click
other
Details
links.