Why does Toad actively suppress ROWID columns in Editor Data Grids when they are explicitly included in a select list such as:
select rowid, name from sys.obj$ where name = 'DBA_USERS';
That works just fine in sqlplus, but Toad 26.1 suppresses the ROWID column from the grid without error or comment. Moreover, if I just "select rowid...", it returns 2 rows in the grid for the above query as would be expected, but the single column returned has no heading or data for both rows. It is just an empty heading and NULL results--but with the correct number of rows.
Running such a query as a script (F5) does not have this problem. This is only a problem with data grids after running (F9) a query.
Now, if I give an alias to the ROWID column, as long as it is not "ROWID", it returns a populated column having the alias as the heading.
Cheers,
Russ
Hi Russ,
Toad uses ROWID so that grids can be editable. We hide ROWID by default because it would be annoying to see it all the time.
If you always want to see it, go to Options -> Data Grids -> Data and check "Show ROWID in editable grids". (in the "Display" groupbox)
If you sometimes want to see it, you can do one of these:
- Alias it with something like:
Select ROWID as my_rowid, ..... (as you noted)
- Use the column selector widget (top left corner of grid) to make ROWID visible.
I suspect that the "make always visible" is something that I knew and had forgotten about.
Um...no...don't want that.
It makes sense, though. I certainly don't want to always see ROWID, but it sure messed me up during a demonstration that I was doing recently in Teams. I could not remember how to get at that and had to drop down to sqlplus.
Cheers,
Russ
To be clear, the "Always" option only shows ROWID if it is actually selected. Toad won't select it behind the scenes (unless Toad is writing the entire SQL, like when you do "Edit Tablename", or go to a table's data tab in schema browser RHS.
LOLs Yeah, well, who wants ROWID in all (or at least most) Schema Browser data grids? I guess someone does, but I don't.
Cheers,
Russ