# Data Mapping cfxdm - dm:to\_type

**dm:to\_type:** It allows to change or set the data type to string or integer (numeric) or float for specified columns.&#x20;

@param '**columns**' (mandatory, comma separated list of column names), @param '**type**' (mandatory, supported options are: str / int / float)

**dm:to\_type:** Syntax

* **columns** (mandatory)**:** Comma-separated list of column names
* **type** (mandatory)**:** Supported options are: **str** (string or text) / **int** (integer or numeric) / **float**

### Example 1:

Step 1: Create an empty **dm\_to\_type\_example\_1** using AIOps studio as shown in the below screenshot

![Empty pipeline](/files/-Mg7cLjdud1l92kL-yHT)

*`##### This pipeline creates a set of records/dateset details with different datatypes`*\
*`##### String and integer.`*\
\
*`######  This pipeline uses dm to_type to convert basic string data type to int datatype`*\
\
~~*`--> @dm:empty`*~~ \
~~*`--> @dm:addrow id = 'a1' & x = '10.0' & y = '3.11' & z = 9`*~~                                \
~~*`--> @dm:addrow id = 'a2' & x = '1.0' & y = '13.0'  & z = 4`*~~ \
~~*`--> @dm:addrow id = 'a3' & x = '7.0' & y = '3.0'   & z = 3`*~~ \
~~*`--> @dm:addrow id = 'a4' & x = '4.0' & y = '-1.4'  & z = 9`*~~\
&#x20;~~*`--> @dm:to_type columns ='x,y' & type = 'int'`*~~<br>

![Pipeline code added to above created empty pipeline](/files/-Mg7eyUXjK_Qc-8qGHoL)

Step &#x33;**:** Click verify button to verify the pipeline. RDA will verify the pipeline without any errors (as shown below)

![Pipeline code verified ](/files/-Mg7fSEHnOf_t581WXNC)

Step &#x34;**:** Click execute button to execute the pipeline. RDA will execute the pipeline without any errors (as shown below)

![Pipeline execution without any errors](/files/-Mg7fs75-TQyKWKhWHED)

Step 5: Verify that the output data is enriched with the requested column names and print the output as shown in the below screenshot.

![](/files/-Mg7gO7s5WU3zv7b7OKa)

As shown in the above pipeline, this function is used to convert string to int (or float) datatype needed for any integer manipulation, etc.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cloudfabrix.io/rda/rda-userguide/rda-aiops-studio/examples-jupyter/data-mapping-cfxdm-dm-to_type.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
