I have a requirement in my project where I have to concatenate the text value to hexadecimal \x01.
I am using this hexadecimal \x01 as delimiter in MFL transform where the transform awaits \x01 at the end of the string.
The query is like : fn:concat("abcd",'\x01')
When I am exceuting the above query,the value \x01 gets concatenated to the text "abcd" and behaves as string and the MFL is not able to identify it as a hexadecimal (\x01) value.
The O/P is : abcd\x01
However.I want the value \x01 to be represented as hexadecimal 1 as I am using hexadecimal 1 (i.e. \x01) as delimiter in MFL transformation.
With the staement fn:concat("abcd",'\x01'),I get XQuery exception while parsing the data.
Can anyone please help me with the hexadecimal notation in XQuery and with the correct syntax of above XQuery to concatenate hexadecimal value to a string.
Thanks in advance,
Would like to give more information on the requirement I have:
I receive text data from an I/P source that contains fields delimited with hexadecimal 01 value(i.e.\x01).This hexadecimal delimiter looks like a square bracket ()in the incoming text file but is actually a hexadecimal 01.The last field in the file is not followed by a delimiter.
I have written a MFL that uses hexadecimal 01(i.e. \x01) as the delimiter value.The Proxy Service reads the incoming text file .In the message flow,I parse the file content using the MFL I have created.
Since the last field in the file is not followed by hex-01 delimiter,I am trying to explicitly concatenate hex-01 to the last field before using MFL transform otherwise my XQuery will fail.
I don't know how to concatenate hexadecimal to the last field.I tried several ways but the data gets concatenated as text and not as hex delimiter.
Can you please help me with the statement that will concatenate hex-01 delimiter value to the text data so that my Query does not fail.