5.7.2标签分离格式

当以批处理模式运行MySQL Shell时,默认使用制表符分隔格式打印结果集,以便为自动分析提供更好的输出。

要在交互模式下运行时获得此输出格式,请使用——result-format =选项卡命令行选项(或其别名——选项卡),或者设置MySQL Shell配置选项resultFormat选项卡

例5.2 Tab分隔格式输出

MySQL localhost:33060+ ssl world_x JS > shell.options.set('resultFormat','tabbed') MySQL localhost:33060+ ssl world_x JS > sessionsql("select * from city where countrycode='AUT'") ID Name countrycode District Info 1523 Wien AUT Wien {"Population": 1608144} 1524 Graz AUT Steiermark {"Population": 240967} 1525 Linz AUT North Austria {"Population": 188022} 1526萨尔茨堡AUT萨尔茨堡{"Population": 144247} 1527 Innsbruck AUT Tiroli {"Population": 111752} 1528 Klagenfurt AUT Kärnten {"Population": 91141} 6行in set(0.0041秒)