Question & Answer
Question
How can I display non-printable characters (i.e. tabs, linefeeds, carriage returns) from a file in Linux?
Answer
To display non-printable characters (for example, tabs, line feeds, carriage returns, etc.) from a file in Linux, run the following command:
- od -c
For example, if the file contains the following:
======================================================================
select inv_num,
inv_dt,
quantity
from invoices;
======================================================================
od -c will return:
0000000 s e l e c t i n v _ n u m , \
0000020 \\t i n v _ d t , \
\\t q u a n t i
0000040 t y \
f r o m \\t i n v o i c e s
0000060 ; \
\
0000063
In the above output a \\t is indicative of a tab character and a \ is indicative of a newline.
The above can be helpful when trying to understand why an nzload may reject a line for insertion.
[{"Product":{"code":"SSULQD","label":"IBM PureData System"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":null,"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"1.0.0","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]
Historical Number
NZ898874
Was this topic helpful?
Document Information
Modified date:
17 October 2019
UID
swg21572026