Bug #58210 Allow Resluts Tabs to have Meaningful Names
Submitted: 15 Nov 2010 20:14 Modified: 16 Nov 2010 5:01
Reporter: Wes Grant Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S4 (Feature request)
Version:5.2.27 OS:Any
Assigned to: CPU Architecture:Any
Tags: Results Tab Naming

[15 Nov 2010 20:14] Wes Grant
Description:
It would be nice to be able to name Results Tabs to something other than Result(1), etc...

I would suggest that if I ran a query like:

SELECT * FROM user u JOIN location l ON u.location_id = l.id AS user_location

... that the tab be named Result(user_location)

This would be very helpful when my script contains multiple select statements.

How to repeat:
Open the SQL editor and run the following query:

SELECT * FROM user AS user;
SELECT * FROM location AS location;

The Results Tab has the following named tabs:

Result(1)
Result(2)

Suggested fix:
named tabs should be:

Result(user)
Result(location)
[16 Nov 2010 5:01] Valeriy Kravchuk
Thank you for the feature request.
[16 Nov 2010 15:22] Alfredo Kojima
Suggested SQL syntax will cause problems, but we could maybe use the 1st comment in the query for the resultset or a comment at the end of the query, if possible, eg:

--- resultname
select 1;

or

select 1 /** resultname */;
[5 Apr 2017 9:42] MySQL Verification Team
Bug #85629 marked as duplicate of this one
[9 May 2019 6:50] Burkhard Vogel
I'd really like the idea of the comment, and as other GUIs already use a 
-- title: myQueryTabName 
syntax, that should probably the way to go? This feature would really be helpful!
[3 Jul 2022 2:37] Fraser Parke
I'm very surprised this hasn't been implemented yet.  This is an 11 and a half year old request.

As this is a database query feature request and this program is used to display and interpret data, it seems self-evident that having the ability to name tabs where a great many tabs may exist, is important functionality, not to mention an easy fix.

As said above, "-- title: xyz", like your competitors.
[16 Sep 20:15] William Donaldson
Functionality to rename tabs is already there. Can we please get this implemented to do it in code ASAP. MySQL sales Rep is sending emails to push 9.0. Oracle MySQL Team putting on Live Webinars about data migration and new features of 9.0. I am slowly moving to MySQL Workbench from SQL Developer and SQL Workbench. Sell me on it like they are selling me on MySQL. I've been working in 9.0 for 3 long weeks now after working in Oracle since 1998. 

All the focus, resources and money Oracle invested pushing 9.0 and MySQL's only advertised frontend development environment does not even have namable tabs yet! Come on guys this has been requested for 15 years! Read comment line before the SQL. This is what we need. -- title:NameOfTabHere
Thanks - Will

USE xxispec;
-- title:Group Versions
SELECT toolingid, COUNT(id) cnt FROM mold GROUP BY toolingid ORDER BY toolingid;
-- title:ToolingID Multi
SELECT r.toolingid FROM (SELECT toolingid, COUNT(id) cnt FROM mold GROUP BY toolingid) r WHERE r.cnt > 1 ORDER BY r.toolingid;
-- title:Mold Versions
SELECT 
    xxispec.mold_moldname(id) AS mold_name,
    xxispec.tooling_moldname(id) AS tooling_mold_name,
    specs,
    remarks,
    toolingid,
    id
FROM 
mold 
WHERE 
toolingid IN (SELECT r.toolingid FROM (SELECT toolingid, COUNT(id) cnt FROM mold GROUP BY toolingid) r WHERE r.cnt > 1) 
ORDER BY toolingid;