You are on page 1of 26

Other Database Features

InfoPlus.21 Foundation Course

©2004 AspenTech. All Rights Reserved.


Objectives
• On conclusion of this module, you will:
– Understand the field processing options available, including
real-time summaries and data logging options
– Understand the mechanism behind record processing and
record activation
– Be aware of two types of records that activate other records
– Introduce Custom Record structures and the Definition Editor

©2004 AspenTech. All Rights Reserved.


Glossary of Terms
• Activation, Record Activation
• Field processing
• Record processing

©2004 AspenTech. All Rights Reserved.


Lesson Overview
• In this lesson, we will discuss:
– Field Processing, including:
• Alarm Summary Processing
• Data Logging
– Record Processing, including:
• Explanation of mechanism
• Review of common types of processing available
• Activation methods
– Custom Record Structures

©2004 AspenTech. All Rights Reserved.


Field Processing – Alarms
• Field processing occurs when one field in a record acquires a value,
and other fields in the same record are
automatically updated
• Examples of field processing we IP_INPUT_VALUE 42
have seen in tags are: IP_INPUT_TIME 2-JUN-98
????? 12:00
– Timestamp and sequence Updates
IP_TREND_SEQ_# 100
101
– Limit Checking
– Boxcar Data Compression IP_HIGH_LIMIT: 40
IP_LOW_LIMIT: 0
• Other kinds of field processing IP_ALARM_STATE: HIGH
OK
that exist within tags include:
– Alarm Summary Processing IP_DC_SIGNIFICANCE: 1.0
– Logging Boxcar
IP_DC_STATUS: No Violation

©2004 AspenTech. All Rights Reserved.


How Alarm Processing Works
1. Alarm occurs in 2. Field Processing sends
any IP21 tag record a signal to the
Alarm Processing Record
IP_INPUT_VALUE:
IP_INPUT_VALUE:
NAME : ATCAI
IP_INPUT_VALUE:
IP_ALARM_STATUS:
IP_INPUT_VALUE:
IP_ALARM_STATUS:
IP_INPUT_VALUE: 42
IP_ALARM_STATUS:
100
IP_PIMSAlarmline
IP_ALARM_STATE: High
OK Alarm Processing
3. A Summary record maintains a dynamic and
list of alarms for all IP21 tags Message Formatting
Reactor Area Alarms Record
Mixer Area Alarms
IP_AlarmSummary
ATCL301 Alarm
4. Formatted alarm
ATC101 Alarm
can appear
ATCAI Alarm immediately on
a GCS Screen

©2004 AspenTech. All Rights Reserved.


How Alarm Processing Works

©2004 AspenTech. All Rights Reserved.


How Data Logging Works (1)
1. Alarm occurs in any InfoPlus.21 tag record. 2. Field Processing sends
IP_Message_Switch is ON a signal to the
Alarm Processing Record

IP_PIMSAlarmline
NAME: ATCAI
Alarm Processing
42
IP_INPUT_VALUE: 100
and
IP_ALARM_STATE: OK
High Message Formatting
IP_MESSAGE_SWITCH: ON Record
3. A log control record filters
the data stream 4. A logging record stores formatted
(configurable conditions) messages in the Historian,
printer also, if required.
IP_AlarmLogCntrl
IP_Log_Record printer
record
Filters record

©2004 AspenTech. All Rights Reserved.


How Data Logging Works (2)

©2004 AspenTech. All Rights Reserved.


Lesson Overview
• In this lesson, we will discuss:
– Field Processing, including:
• Alarm Summary Processing
• Data Logging
– Record Processing, including:
• Explanation of mechanism
• Review of common types of processing available
• Activation methods
– Custom Record Structures

©2004 AspenTech. All Rights Reserved.


Example of Record Processing
• When certain types of records are “Activated,”
they exhibit some processing behavior
SQL
– Example 1:
• Record defined by QueryDef is Activated
• Behavior: SQL contained in #Query_Lines
repeat area is executed

– Example 2: SAVE
• Record defined by DatabaseSaveDef is Activated
• Behavior: A binary image of the entire database is saved to
disk

©2004 AspenTech. All Rights Reserved.


Record Processing Options
Functionality Records Defined By Task

Calculations, Logic and PlantApDef TSK_PLAN


Activation
Saving Snapshots DataBaseSaveDef TSK_SAVE
Execution of record-based QueryDef, ViewDef, TSK_IQ1, TSK_IQ2
SQLplus queries CompQueryDef, etc.
TextViewDef,
ProcedureDef
Transfers of plant TSK_MSIM*
automation data IOGetDef, IOPutDef
Triggering Aspen Calc TSK_CLC1
AspenCalcDef
Calculations
User Defined Processing Custom Definition record TSK_
_???

©2004 AspenTech. All Rights Reserved.


External Task Trigger Mechanism
• Using SQLplus query records as an example….
• How does the data record know what task to wake up?
External External
Task (sometimes) Task
Record Definition
E.g., TSK_IQ1
E.g., TSK_IQ1 Record
E.g., QueryDef
Zzzzzz...

Wake up!
And here’s
“Activation” a message

Data OK,
Record I’ll read SQL from record.
E.g., Query1 Perform Processing.
Then Back to sleep.
©2004 AspenTech. All Rights Reserved.
How Can Records be Activated?
• From Activating Records:
– Special records in the database activate lists of other records
• On a regular schedule (Scheduled Activation)
• When a field in a record changes (COS Activation)

• From Built-In Activation Fields:


– Some records have scheduling or COS mechanisms built-in to their
Definition structures
– Any field can be designed to have activation properties to make field
processing cause activation when a value changes
• For example, EXECUTE field in Query records
• From SQLplus:
– Has an ACTTSK clause to activate other records

• Manually from the InfoPlus.21 Administrator:


– Record context menu has
Activate option
©2004 AspenTech. All Rights Reserved.
Scheduled Activation Records
• Useful to activate lists of different kinds of records on a common
schedule: Defined from ScheduledActDef

When is the first Fixed Area:


(Next?) activation? How often shall I
activate records?
How Often?
How many records
do I activate?

Read from plant


Do Calc on value
Repeat Area:
Which records shall
SQL Report
I activate?
©2004 AspenTech. All Rights Reserved.
Change of State Activation
• Activates each record in list automatically when a
specified database field changes value
I’m COSActDef Record: Fixed Area
watching
Tag Record: Valve1 you! Wait_for_COS_field: Valve1 IP_Value
COS_Recognition: all
IP_Value: 1
0 Set_Option: set to 0

COSAct Record: Repeat Area


Record_Name: ExampleCalc
Record_Name: ExampleReport
ExampleCalc

ExampleReport
©2004 AspenTech. All Rights Reserved.
COS Activation Record Example
• Useful to activate lists of different kinds of records on a common
event: defined from CosActDef

I’m watching…
Which record? Which field?

What kind of change?

How many records


do I activate?

Start a calculation
Repeat Area:
and a report
Which records shall
I activate?
©2004 AspenTech. All Rights Reserved.
T

Built-In Activation Fields


• Some records incorporate scheduling, change of state, or other
activation options into built-in field
• Example: records defined from QueryDef

©2004 AspenTech. All Rights Reserved.


Activations: Lab
• In this Lab, you will:
– Configure a trigger for the Saltlevel calculation set up
previously

©2004 AspenTech. All Rights Reserved.


Lesson Overview
• In this lesson, we will discuss:
– Field Processing, including:
• Alarm Summary Processing
• Data Logging
– Record Processing, including:
• Explanation of mechanism
• Review of common types of processing available
• Activation methods
– Custom Record Structures

©2004 AspenTech. All Rights Reserved.


Custom Record Structures
• Create own customized tag set if standard tag set not a good “fit” for
your application
• Create application specific records, for example:
– DownTimeDef
– MachineDef
– RecipeDef
– ProductionScheduleDef

• Can feature:
– None, one or practically any number of repeat areas
– Practically any number of fields in each area
– Standard or custom field names
– All field processing options available, including Historization
– Can be processed by custom external task, using activation methods
discussed, or by SQLplus
©2004 AspenTech. All Rights Reserved.
How Custom Records are Created
• Definition Editor GUI is used

©2004 AspenTech. All Rights Reserved.


Creating Custom Definition Records
• Field Names are added, given data types, attached to
processing options to make a Custom Definition Record

©2004 AspenTech. All Rights Reserved.


Custom Record Example

©2004 AspenTech. All Rights Reserved.


Where to Find Out More...
• InfoPlus.21 Application Development Course fully
explains the features described in this module, with
hands-on exercises
• Topics included are:
– Customizing Summaries
– Customizing Data Logging
– Field Processing
– Record Processing and Activation
– Writing Custom External Tasks
– Creating Custom Definition Records
– Writing client-side applications in Visual Basic

©2004 AspenTech. All Rights Reserved.


Review
• InfoPlus.21 records can incorporate many automatic field processing
options, including:
Update generation Limit Checking Field Validation
Alarm Summary population Data logging

• InfoPlus.21 has a mechanism by which records can be activated to


begin some processing behavior that is actually carried out by
processes called External Tasks
• Activations can occur on a regular schedule, on a change of value in
the database, or as a result of other processing options (for
example, SQLplus)
• Custom Records can be produced to hold any kind of information,
and can incorporate any of InfoPlus.21’s processing options found in
standard records

©2004 AspenTech. All Rights Reserved.

You might also like