Support Article
Query regarding Type1 column having alpha-numeric values
SA-38109
Summary
User has a Customer Data View (CDV) in which the type1 column is inserted with <datetimestamp>_MobileNumber values. Though these values are non-numeric, CAMP_RESULT_PROC.LAST_SEL_ORDER is updated.
Resolution
To update the value of sel_order, the C function used is atoi, which takes in the varchar value present in type_1 column and converts it to integer. If the converted integer is not zero, then the value is incremented. However, if the converted integer is zero, then the sel_order remains as zero.
The behaviour of the atoi function is such that, it skips all white-space characters at the beginning of the string, converts the subsequent characters as part of the number, and stops when it encounters the first character that is not a number.
For the value, ALL1 in type_1 column, the atoi function encounters a character which is not a number in the first iteration, hence stops the conversion which results in sel_order value not incremented.
However, in the type_1 column where <datetimestamp>_mobileNumber is inserted, the atoi function converts all numbers until the underscore is encountered and then stops the operation. Since the returned value is not zero, the sel_order value is updated as per design.
Published November 8, 2017 - Updated December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.