In Percona Support we spend a few hours per week doing Labs: short collective projects, not directly related to the tickets. One of our last labs was about to get ready for the winter holiday season which means preparing the tree and decorating it. To do it we used our favorite tools: MySQL, and ASCII art (https://en.wikipedia.org/wiki/ASCII_art). As a result, we created a function that prints into the terminal a New Year Tree (https://en.wikipedia.org/wiki/New_Year_tree) and decorates it with symbols we want. For example, to create a three-level tree, decorated with starts, call the function as follow:
$ mysql ny_tree -e "select ny_tree(3, '*')" --vertical --skip-column-names -s *************************** 1. row *************************** /\ /__\ /* \ /____\ / * \ /______\ ||
Since MySQL supports Unicode you can use any symbol, having it has …
[Read more]