////
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at
  http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.
////

== Data types

As a best practice for producing consistent, predictable outcomes when working with your data in Apache Hop, you must consider how the Apache Hop engine processes different data types and field metadata in transformations and jobs.

NOTE: As a rule, data is never modified by metadata inside of Apache Hop. Data is only modified when Apache Hop writes to files or similar objects, but not to databases.

Apache Hop data types map internally to Java data types, so the Java behavior of these data types applies to the associated fields, parameters, and variables used in your workflows and pipelines. The following table describes these mappings.

[options="header", width="90%", cols="1,1,3"]
|===
|Apache Hop|Java data type|Description
|BigNumber|BigDecimal|An arbitrary unlimited precision number.
|Binary|Byte[]|An array of bytes that contain any type of binary data.
|Boolean|Boolean|A boolean value true or false.
|Date|Date|A date-time value with millisecond precision.
|Integer|Long|A signed long 64-bit integer.
|Internet|Address|InetAddress	An Internet Protocol (IP) address.
|Number|Double|A double precision floating point value.
|String|String|A variable unlimited length text encoded in UTF-8 (Unicode).
|Timestamp|Timestamp|Allows the specification of fractional seconds to a precision of nanoseconds.
|===

NOTE: Apache Hop also comes with a number of additional complex data types (e.g. Avro, JSON, Graph) that have no one-on-one mapping to Java data types. These data types only work with specific transforms and can't be used in general-purpose transforms.