String Cut
Overview
The String Cut operator cuts existing fields to generate new fields.
Input and Output
- Input: fields to be cut
- Output: new fields
Parameter Description
Parameter |
Description |
Type |
Mandatory |
Default Value |
---|---|---|---|---|
Fields to be cut |
Information about a cut field:
|
map |
Yes |
None |
Data Processing Rule
- start position and end position are used to cut the original fields and generate new fields.
- If end position is set to -1, the end of a string is to be cut. In other cases, the value of end position must be greater than the value of start position.
- If the value of start position or end position is greater than the length of the input field, the line will become dirty data.
Example
Use the CSV File Input operator to generate fields A and B.
The following figure shows the source file.
abcd,product FusionInsight,Bigdata
After configuring the String Cut operator, fields C and D are generated.
After cutting, the following fields are generated.
abcd,product,abc,prod FusionInsight,Bigdata,Fus,Bigd
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.