# Data types

This table describes how to use the data types supported by Data Shaping Expression Language.

| Type | Syntax | Examples | Corresponding Java class |
| --- | --- | --- | --- |
| String | Strings should be delimited by single or double quotes. If you want to<br>use quotes in your string, you can escape them with \ or use<br>different quotes than the ones used to delimit the string. You can also use the<br>following sequences to escape: \n, \r,<br>\f, \t, \b,<br>\/, \' in case of single quoted string,<br>and \" in case of double quoted string.<br><br>CR, NL, and LF are<br>not allowed in a quoted string. | ```<br>'blue'<br>"yellow"<br>"John \"Big\" Doe"<br>"John 'Big' Doe"<br>``` | java.lang.string |
| Integer | Integers are whole numbers, positive, or<br>negative. | ```<br>1<br>-42<br>2147483647<br>``` | java.lang.Integer |
| Long | Long values should be followed by l or L to be<br>interpreted as long. Otherwise they are interpreted as<br>integers. | ```<br>1l<br>-42L<br>9223372036854775807L<br>``` | java.lang.Long |
| Double | Double values should written in scientific notation<br>or be followed by d or D to be interpreted as double. Otherwise<br>they are interpreted as decimals. | ```<br>1.5d<br>5D<br>-.1415d<br>-4.73E-2<br>``` | java.lang.Double |
| Float | Float values can be written in scientific notation.<br>They should be followed by f or<br>F to be interpreted as float.<br>Otherwise they are interpreted as double if they contain scientific<br>notation, or decimal if they do not. | ```<br>3.1415f<br>1.5e-2f<br>5F<br>``` | java.lang.Float |
| Decimal | Decimals are numbers with a decimal point | ```<br>0.3<br>-1.17<br>``` | java.math.BigDecimal |
| Boolean | Booleans are case insensitive. | ```<br>True<br>false<br>FALSE<br>``` | java.lang.Boolean |
| Bytes | Bytes should be written with hexadecimal characters<br>in lowercase or uppercase, prefixed by 0x or<br>0X. | ```<br>0xFFFFFF<br>0X1234567890<br>0x0a6e<br>``` | byte[] |
| Date | Dates should be delimited by single or double quotes. They are<br>composed of a year, month and day in the format yyyyMMdd, yyyy/MM/dd or<br>yyyy-MM-dd. To evaluate them as<br>dates instead of strings, you need to use a toDate function. See [Data type functions](https://help.qlik.com/talend/en-US/data-shaping-language-reference-guide/8.0/data-type-functions "The following functions can be used to check values and data types, and to convert a value to another data type."). | ```<br>'2019-08-05'<br>"1981/09/12"<br>'20170223'<br>``` | java.time.LocalDate |
| Time | Times should be delimited by single or double quotes. They are composed<br>of hours and minutes, and can also contain seconds, milliseconds, and a<br>timezone. The format should be HH:mm,<br>hh:mm:ss or HH:mm:ss.SSS To evaluate them<br>as times instead of strings, you need to use a toTime<br>function. | ```<br>"09:44"<br>'12:32:25'<br>"09:51:32.568"<br>"01:02:03.456+03:00"<br>``` | <ul> <li> <span>java.time.LocalTime</span></li> <li><span>java class java.time.OffsetTime</span></li> </ul> |
| Datetime | Datetimes should be delimited by single or double quotes. They are<br>composed of a date and a time, with an optional timezone. The format should<br>follow the international standard ISO 8601. To evaluate them as datetimes<br>instead of strings, you need to use a toDateTime<br>function. | ```<br>"2017-07-02T15:04:05.567-08:00"<br>'2024-05-07T14:27'<br>``` | <ul> <li><span>java.time.OffsetDateTime</span> </li> <li><span>java class java.time.LocalDateTime</span></li> </ul> |

### In this section

* [Automatic data type conversion](https://help.qlik.com/talend/en-US/data-shaping-language-reference-guide/8.0/automatic-data-type-conversion)