Skip to content

Escape Sequences for Non-Printable Characters

The following table shows valid escape sequences for commonly used non-printable characters.

DecBackslash CharBackslash OctalHexBackslash SQL Unicode (4) **Backslash SQL Unicode (6) **ybload Unicode (2,4,6,8)***AbbreviationDescription
0\0 *\000\x00\u0000\U000000U+0000NULnull
1\001\x01\u0001\U000001U+0001SOHstart of header
2\002\x02\u0002\U000002U+0002STXstart of text
3\003\x03\u0003\U000003U+0003ETXend of text
4\004\x04\u0004\U000004U+0004EOTend of transmission
5\005\x05\u0005\U000005U+0005ENQenquiry
6\006\x06\u0006\U000006U+0006ACKacknowledge
7\007\x07\u0007\U000007U+0007BELbell
8\b\010\x08\u0008\U000008U+0008BSbackspace
9\t\011\x09\u0009\U000009U+0009HThorizontal tab
10\n\012\x0A\u000A\U00000AU+000ALFline feed
11\013\x0B\u000B\U00000BU+000BVTvertical tab
12\f\014\x0C\u000C\U00000CU+000CFFform feed
13\r & \m\015\x0D\u000D\U00000DU+000DCRenter / carriage return
14\016\x0E\u000E\U00000EU+000ESOshift out
15\017\x0F\u000F\U00000FU+000FSIshift in
16\020\x10\u0010\U000010U+0010DLEdata link escape
17\021\x11\u0011\U000011U+0011DC1device control 1
18\022\x12\u0012\U000012U+0012DC2device control 2
19\023\x13\u0013\U000013U+0013DC3device control 3
20\024\x14\u0014\U000014U+0014DC4device control 4
21\025\x15\u0015\U000015U+0015NAKnegative acknowledge
22\026\x16\u0016\U000016U+0016SYNsynchronize
23\027\x17\u0017\U000017U+0017ETBend of trans. block
24\030\x18\u0018\U000018U+0018CANcancel
25\031\x19\u0019\U000019U+0019EMend of medium
26\032\x1A\u001A\U00001AU+001ASUBsubstitute
27\033\x1B\u001B\U00001BU+001BESCescape
28\034\x1C\u001C\U00001CU+001CFSfile separator
29\035\x1D\u001D\U00001DU+001DGSgroup separator
30\rs*\036\x1E\u001E\U00001EU+001ERSrecord separator
31\us*\037\x1F\u001F\U00001FU+001FUSunit separator
127\177\x7F\u007F\U00007FU+007FDELdelete

Notes:

  • * These sequences are for ybload and ybunload only.
  • ** These sequences are separate from the U&'\nnnn and U&\+nnnnnn escape sequences.
  • *** These sequences are for ybload and ybunload only. They can be 2, 4, 6, or 8 hex digits wide.

Parent topic:SQL String Constants