Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Description

Removes the white space from the beginning and the end of a string.

How does it work in the search window?

This operation needs only one argument:

Argument

Data type

String to be trimmed mandatory

string

The data type of the new column is string.


Example


Select Create column from the query toolbar and select Trim both sides as the operation. Call it trimmed_both. 

The arguments needed are: 

  • String to be trimmed - -1to1Values column

The result is not visible in the interface, since the search window table automatically trims blank spaces at both sides of the strings. Select Download from the toolbar and download the data as a CSV to see the data trimmed.

How does it work in LINQ?

Use the operator select... as...  and add the operation syntax to create the new column. This is the syntax of the Trim both sides operation:

  • trim(string)

Example

Copy the following LINQ script and try the above example:

from my.upload.trim.operation
select split(message, ",", 0) as `-1to1Values`
select trim(`-1to1Values`) as usrcol1
  • No labels