String Cut
Overview
String Cut: cuts existing fields to generate new fields.
Input and Output
- Input: fields to be truncated
- Output: new fields generated after truncation
Description
Parameter |
Description |
Type |
Mandatory |
Default Value |
---|---|---|---|---|
Fields to be cut |
Information about a cut field:
|
map |
Yes |
None |
Data Processing Rule
- Use the start position and end position to cut the original field value and generate a new field.
- If the end position is -1, it indicates the end of a field. In other cases, the end position cannot be smaller than the start position.
- If the start or end position of the string to be cut is greater than the length of the input field, the current line becomes dirty data.
Example
Use the CSV File Input operator to generate two fields: A and B.
The source file is as follows:
abcd,product FusionInsight,Bigdata
After String Cut operator is configured, fields C and D are generated.
After the conversion, 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.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot