[TOC] [Prev] [Next] [Bottom]



<@DSNUM>

Syntax

<@DSNUM NUM=num [ENCODING=encoding]>

Description

Converts a number to the format required by the current action's data source. The main use for this tag is in Direct DBMS actions. In the other types of database actions (Search, Update, Insert, and Delete), Tango performs the required conversion automatically.

This meta tag is valid only in actions associated with a data source.


!Note: Conversion of a number involves removal of thousand separator and currency characters, trimming of spaces from the beginning and end, and substitution of decimal characters with the character required by the DBMS.


FileMaker Pro

This meta tag is not applicable to FileMaker Pro data sources (Mac OS) as the number formats required for FileMaker Pro are determined by layout and system settings that may be unavailable to Tango.

Example

UPDATE myTable SET theNumericColumn=<@DSNUM NUM=<@POSTARG NAME=num>>

This example assumes the user has entered "$2000.00" into the number form field, and that the system configuration variable currencyChar is set to "$", thousandsChar is set to "." and that decimalChar and DBDecimalChar are both set to "."; <@DSNUM> tag returns "2000.00".

See Also

currencyChar
DBDecimalChar
decimalChar
<@DSDATE>, <@DSTIME>, <@DSTIMESTAMP>
Encoding Attribute
thousandsChar



[TOC] [Prev] [Next] [Bottom]



docs@pervasive.com

Copyright © 1998, Pervasive Software Inc. All rights reserved.