DISC

Contents | What's New | Quick Links

 

SQL Functions

Introduction

Software Installation

Concepts and Design

Designing Applications

Omnidex Environments

SQL Reference

Omnidex API's

Utilities

Interfaces

Performance Guide

Troubleshooting Guide

Appendix

 

 

$ROUND

 

The $ROUND function returns a numeric expression rounded to a specified number of decimal places.

If the value specified by n is positive and longer than the digits after the decimal point, 0 is added after the fraction digits.

If the value specified by n is negative and larger than or equal to the digits before the decimal point, 0.00 is returned.

Syntax

Example

SQL Reference

Commands

Functions

 

Syntax

$ROUND(expression [,n])

$ROUND()

Required.

expression

Required. A valid numerical value. This can be a column in a select statement that will return a numerical value.

n

Optional. n is an integer indicating the number of digits to the right of the decimal. The default is 0.

top

 

Example

$ROUND(123.4545, 2) result: 123.4500

$ROUND(123.4545, -2) result: 100.0000

$ROUND(123.9994, 3) result: 123.9990

$ROUND(123.9995, 3) result: 124.0000

 

 

top

Dynamic Information Systems Corporation - Omnidex Version 3.8 Build 6 J15.03-Copyright © 2003

DISC | Documentation Home