# Data types

**URL:** <https://forum.knime.com/t/data-types/43949>\
**Category:** KNIME Analytics Platform\
**Created:** [June 8, 2022, 7:20pm UTC](https://forum.knime.com/t/data-types/43949 "2022-06-08T19:20:35Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pedro87](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/p/ebca7d/32.png) [@Pedro87](https://forum.knime.com/u/Pedro87)\
**Post date:** [June 8, 2022, 7:20pm UTC](https://forum.knime.com/t/data-types/43949/1 "2022-06-08T19:20:36Z")

</div>

Dear All

Along with greeting, I present the following doubt and understanding in knime about data types:  
Data type “string” is of type text for example Pedro  
Data type “Number (integer)” is of type numeric example 1.000 etc.  
Data type “Number (double)” is of decimal type example 4,5.  
Data type “Period” is of type date example 12-05-2022

Is my understanding of the above correct?

As a precedent in Chile, the thousands separator is the “.” and the decimal separator is “,” likewise the date in my country is handled in the following way DD-MM-YYYY

Therefore, when loading a database in knime in the cvs node, it transforms the data from dates to string or from number (integer) to number (double), therefore:  
How do I carry out correct data processing correctly?

An example image is attached.

 ![Captura](https://forum-cdn.knime.com/uploads/default/original/3X/b/4/b45482fa863648ea73544140d6d6f27b506c489c.png)

---

<div class="post-metadata">

**Author:** ![mlauber71](https://forum-cdn.knime.com/user_avatar/forum.knime.com/mlauber71/32/73590_2.png) [@mlauber71](https://forum.knime.com/u/mlauber71)\
**Post date:** [June 8, 2022, 9:29pm UTC](https://forum.knime.com/t/data-types/43949/2 "2022-06-08T21:29:51Z")

</div>

@Pedro87 when you import CSV (or Excel) files you can change several options to adapt to local settings like decimal separators. The internal format in KNIME would follow English (US) standards - once you have imported eg. date and time variable you can safely use / calculate them.

> **[CSV Reader](https://hub.knime.com/knime/extensions/org.knime.features.base/latest/org.knime.base.node.io.filehandling.csv.reader.CSVTableReaderNodeFactory)**
>
> Reads CSV files. To auto-guess the structure of the file click the Autodetect format button. If you encounter problems with incorrect guessed data types disabl…

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/6/d/6d4e307417c2caf2867ad34ffb206992ae5b7504.jpeg)

If you have very special date and time formats you might first import them as strings and convert them later.

If you want to write to a database KNIME will try to determine the best format but the DB nodes also offer the options to set special formats and types the KNIME column types might be converted to.

If you have specific questions it might be best to provide us with an example file that might show what you want to do.

---

<div class="post-metadata">

**Author:** ![Pedro87](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/p/ebca7d/32.png) [@Pedro87](https://forum.knime.com/u/Pedro87)\
**Post date:** [June 9, 2022, 12:48pm UTC](https://forum.knime.com/t/data-types/43949/3 "2022-06-09T12:48:43Z")

</div>

Hi Mlauber71

I understand that I must import the file to Knime with the string type format that is currently done in some fields automatically (attached an outstanding image in yellow).

What I need is to transform the following String fields to Date with the following structure DD -MM -YYYY where DD → day, MM → month and YYYY → year  
Field 1: Audit\_\_fec\_Process  
Field 2: Fec\_vent  
Field 3: FEC\_PAGO\_DIVIDENDO

Note  
Field 1, 2 and 3 have the same information structure YYYY-MM-DD HH: MM: SS.MI for example  
2022-05-27 08: 34: 59.000

![Captura](https://forum-cdn.knime.com/uploads/default/original/3X/f/c/fc966b97aaf3b2d351f204daccf624669dd838b6.png)

---

<div class="post-metadata">

**Author:** ![mlauber71](https://forum-cdn.knime.com/user_avatar/forum.knime.com/mlauber71/32/73590_2.png) [@mlauber71](https://forum.knime.com/u/mlauber71)\
**Post date:** [June 9, 2022, 1:10pm UTC](https://forum.knime.com/t/data-types/43949/4 "2022-06-09T13:10:33Z")

</div>

@Pedro87 I think you need a different pattern. Also you want to use yyyy in lower case in general (cf. these threads [1](https://forum.knime.com/t/an-example-what-can-go-wrong-with-datestimes-in-knime-the-string-to-date-time-node/43572/7)|[2](https://forum.knime.com/t/serious-error-in-date-time-to-string-node/43211/6)).

`yyyy-MM-dd HH:mm[:ss[.SSS]]`

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/3/c/3cfc5dad2a512ee8ba3fa868784f200f1dc74230.png)

> **[Forum question about Date and Time Strings (43949) – mlauber71](https://hub.knime.com/mlauber71/spaces/Forum/latest/2022/kn_forum_43949_date_format~BFNQ0c2G5qpu8Sxq)**
>
> Forum question about Date and Time Strings (43949)

[kn\_forum\_43949\_date\_format.knwf](https://forum.knime.com/uploads/short-url/aSgTXWMGAC93LAjgIG3QuNWk676.knwf) (8.4 KB)

---

<div class="post-metadata">

**Author:** ![Pedro87](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/p/ebca7d/32.png) [@Pedro87](https://forum.knime.com/u/Pedro87)\
**Post date:** [June 9, 2022, 2:03pm UTC](https://forum.knime.com/t/data-types/43949/5 "2022-06-09T14:03:17Z")

</div>

Thank you very much @mlauber71 it worked

Greetings and good day

---

<div class="post-metadata">

**Author:** ![system](https://forum-cdn.knime.com/uploads/default/original/1X/ab3ccf34482a0329361734a18199390177204f15.png) [@system](https://forum.knime.com/u/system)\
**Post date:** [September 7, 2022, 2:03pm UTC](https://forum.knime.com/t/data-types/43949/6 "2022-09-07T14:03:32Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
