My client uses incredibly long, descriptive table names, which is great except when I'm looking at open tabs in DbVis. I definitely want the table name in the tab label, but that pretty much guarantees I'll only be able to fit 1 or 2 tabs in a normal window.
One possible solution, which might be useful in other use cases, is to expand the "tab header" possibilities by adding optional modifiers to the brace-enclosed keywords like this:
${objectname,a=value,b=value}
where a and b could be:
max_width - maximum number of characters to display
truncate_at - where to truncate (beginning, middle or end of string) value if larger than max_width
font - desired font, including size
If newlines (\n) were allowed in the tab header, a user could easily create, for example, a 2-line tab header with the table name on the 2nd line in a smaller font
Finally, you could have "alias=filename" which would tell DbVis to look up the value in a text file containing aliases, and display the alias instead of the value (if it exists in the file). The file would be just:
long_table_name=l_tn
very_long_table_name=vl_tn
If you wanted to be really fancy you could allow the filename to use other keywords' values. For example, I would create two files named
DB1-ALIASES.TXT and DB2-ALIASES.TXT, and my alias value would be:
alias=${schema}-ALIASES.TXT
1 Comment
Roger Bjärevall
said
almost 7 years ago
Charles,
Thanks for the detailed request. I've opened a ticket and we will have a look.
Charles.basner
My client uses incredibly long, descriptive table names, which is great except when I'm looking at open tabs in DbVis. I definitely want the table name in the tab label, but that pretty much guarantees I'll only be able to fit 1 or 2 tabs in a normal window.
One possible solution, which might be useful in other use cases, is to expand the "tab header" possibilities by adding optional modifiers to the brace-enclosed keywords like this:
${objectname,a=value,b=value}
where a and b could be:
max_width - maximum number of characters to display
truncate_at - where to truncate (beginning, middle or end of string) value if larger than max_width
font - desired font, including size
If newlines (\n) were allowed in the tab header, a user could easily create, for example, a 2-line tab header with the table name on the 2nd line in a smaller font
Finally, you could have "alias=filename" which would tell DbVis to look up the value in a text file containing aliases, and display the alias instead of the value (if it exists in the file). The file would be just:
long_table_name=l_tn
very_long_table_name=vl_tn
If you wanted to be really fancy you could allow the filename to use other keywords' values. For example, I would create two files named
DB1-ALIASES.TXT and DB2-ALIASES.TXT, and my alias value would be:
alias=${schema}-ALIASES.TXT