---
schema_version: "1"
id: 522ad4a1c09c2b360450464078e851f506fcbd7c7e00c7383fed1a4103b14beb
title: DataFormattingOptions | Tableau Embedding API
collection: tableau
version: current
locale: en-us
portal_url: https://docs.salesforce.com/tableau/current/en-us/api/embedding_api/reference/interfaces/DataFormattingOptions.md
canonical_url: https://help.tableau.com/current/api/embedding_api/en-us/reference/interfaces/DataFormattingOptions.html
source_site: help.tableau.com
content_type: documentation
content_hash: cdecc37072320b185f02fefe9017cd0d347d6e8a348ac8d5cce88a37ec6c7267
description: Documentation for Tableau Embedding API
---
- DataFormattingOptions

# Interface DataFormattingOptions

interface DataFormattingOptions {  
    [customFormatString](#customformatstring): string;  
    [decimalCharacter](#decimalcharacter): string;  
    [decimals](#decimals): number;  
    [formatType](#formattype): [DataFormatType](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/DataFormatType.html);  
    [locale](#locale): string;  
    [negativeFormat](#negativeformat): [NegativeNumberFormat](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/NegativeNumberFormat.html);  
    [prefix](#prefix): string;  
    [separatorCharacter](#separatorcharacter): string;  
    [showSeparators](#showseparators): boolean;  
    [suffix](#suffix): string;  
    [units](#units): [NumberFormatUnits](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/NumberFormatUnits.html);  
}

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:425

##### Index

### Properties

[customFormatString](#customformatstring) [decimalCharacter](#decimalcharacter) [decimals](#decimals) [formatType](#formattype) [locale](#locale) [negativeFormat](#negativeformat) [prefix](#prefix) [separatorCharacter](#separatorcharacter) [showSeparators](#showseparators) [suffix](#suffix) [units](#units)

## Properties

### customFormatString[](#customformatstring)

customFormatString: string

#### Returns[](#returns)

The custom format string to display for the value. For more information on number formats, see [Format Numbers and Null Values](https://help.tableau.com/current/pro/desktop/en-us/formatting_specific_numbers.htm). When the custom format string is used for numbers, other formatting options are ignored. For information on formatting dates, see [Custom Date Formats](https://help.tableau.com/current/pro/desktop/en-us/dates_custom_date_formats.htm). The custom format string is always used for dates and the other formatting options do not apply (except for the `formatType` and `locale`).

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:475

### decimalCharacter[](#decimalcharacter)

decimalCharacter: string

#### Returns[](#returns-1)

The character to use as the decimal point.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:443

### decimals[](#decimals)

decimals: number

#### Returns[](#returns-2)

The number of digits to display after the decimal point.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:439

### formatType[](#formattype)

formatType: [DataFormatType](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/DataFormatType.html)

#### Returns[](#returns-3)

The type of the format. Can specify number, currency, date, time, percentage, scientific, or auto-format (default). For numbers, can also specify custom number format.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:431

### locale[](#locale)

locale: string

#### Returns[](#returns-4)

The locale of the format (e.g. en-US, fr-FR, etc.).

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:435

### negativeFormat[](#negativeformat)

negativeFormat: [NegativeNumberFormat](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/NegativeNumberFormat.html)

#### Returns[](#returns-5)

The format for displaying .

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:467

### prefix[](#prefix)

prefix: string

#### Returns[](#returns-6)

The prefix to display before the value.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:455

### separatorCharacter[](#separatorcharacter)

separatorCharacter: string

#### Returns[](#returns-7)

The character to use as the thousand separator.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:451

### showSeparators[](#showseparators)

showSeparators: boolean

#### Returns[](#returns-8)

Whether to show thousand separators.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:447

### suffix[](#suffix)

suffix: string

#### Returns[](#returns-9)

The suffix to display after the value.

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:459

### units[](#units)

units: [NumberFormatUnits](https://help.tableau.com/current/api/embedding_api/en-us/reference/enums/NumberFormatUnits.html)

#### Returns[](#returns-10)

Display the number using specified units (e.g. `K` for thousands, `M` for millions, `B` for billions, etc.).

- Defined in packages/api-external-contract-js/src/ExternalContract/Shared/DataSourceInterfaces.ts:463

### Settings

Member Visibility

- Protected
- Inherited
- External

ThemeOSLightDark

### On This Page

Properties

[customFormatString](#customformatstring)[decimalCharacter](#decimalcharacter)[decimals](#decimals)[formatType](#formattype)[locale](#locale)[negativeFormat](#negativeformat)[prefix](#prefix)[separatorCharacter](#separatorcharacter)[showSeparators](#showseparators)[suffix](#suffix)[units](#units)