Aggregate Editor
Top  Previous  Next


The Aggregate Editor allows you to create new aggregates and to edit the existing ones (see How to create an aggregate and How to edit an aggregate).

Aggregate  
 
The main aggregate parameters are set on the Aggregate tab.

Name
Set the name of the aggregate in the edit field.

Base Type
The input data type on which this aggregate function operates. This can be specified as ANY for an aggregate that does not examine its input values.

State Type
The data type for the aggregate's state value.

State Function
The name of the state transition function to be called for each input data value.

Final Type
This field is auto-calculated, so you don't have to set it manually.

Final Function
The name of the final function called to compute the aggregate's result after all input data has been traversed.

Initial State
The initial setting for the state value. This must be a literal constant in the form accepted for the data type 'state_type'. If not specified, the state value starts out NULL.

Description  
 
The Description tab contains the aggregate description. Button Save Description saves the edited description.

DDL  
 
On the DDL tab you can view the SQL text for creating the aggregate with the properties you set. This text can't be edited, but can be copied to the clipboard.

To call the PostgreSQL Reference, click button Help on SQL on the toolbar.

Button Default Size brings the window to the default size (restricted by the main window and the DB Explorer).

The drop-down list of the current database aggregates on the toolbar allows you to switch the edited aggregate.

When you are done, click button Compile on the toolbar to start the process of compilation. The Compile Window will appear where you will be able to view and edit the result SQL statement for creating the new aggregate. Commit the transaction, and if it is successful, the new aggregate will be created or the aggregate parameters will be changed.

See also:
Table Editor
Schema Editor
View Editor
Function Editor
Rule Editor
Trigger Editor
Sequence Editor
Type Editor
Index Editor
Operator Editor
Language Editor
Compile Window


Availability:
Windows Professional

Yes

Windows Lite

Yes

Linux Professional

Yes

Linux Lite

Yes