Forum Stats

  • 3,769,500 Users
  • 2,252,970 Discussions
  • 7,875,060 Comments

Discussions

sqlcl ansiconsole column alignment

user4668973
user4668973 Member Posts: 3 Red Ribbon
edited Mar 27, 2018 9:58AM in SQLcl

I try to use coloring in sqlcl using sqlformat "ansiconsole". If something is highlighted with a color tag the column become out of alignment.

In below example the first select does no highlighting and column headers and values are in line. In second select objects owned by "SYS" are highlighted, but the header and values are not in alignment.

Does anyone has an idea to get this formatted well?

set sqlformat ansiconsole

SELECT

   OWNER,

   OBJECT_NAME

FROM

   ALL_OBJECTS

WHERE

   OBJECT_NAME='ALL_OBJECTS';

SELECT

   DECODE(OWNER,'SYS','@|BG_RED '||OWNER||'|@',OWNER) OWNER,

   OBJECT_NAME

FROM

   ALL_OBJECTS

WHERE

   OBJECT_NAME='ALL_OBJECTS';

Answers