We're Moving!

The Vertica Forum is moving to a new OpenText Analytics Database (Vertica) Community.

Join us there to post discussion topics, learn about

product releases, share tips, access the blog, and much more.

Create My New Community Account Now


Use \t as separator on command line. — Vertica Forum

Use \t as separator on command line.

How can I force a tab character as a field separator on the command line. I've tried vsql -t -F"\t", -f"\\t" and some variations on E'\09' etc. I have usually just piped to tr to get the job done but I feel there must be a better way. Thx. (sorry if repost, cannot find in FAQ)

Comments

  • vsql takes the literal argument that is passed to it; if you want a tab, you'll have to get your shell to insert a literal tab. How to do this varies from shell to shell. One solution is to type a literal tab into a text editor, and copy/paste it into your shell. If you're using a bash shell, vsql -F $'\t' (with the leading '$') should do it.
  • That worked for me.
    Thanks!

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file