When I issue a query like select * from city; using oracle sql developer in mac I get the output that is not aligned and it is very hard to read. How do I get the grid view and set it as default?
-
And what exactly is not aligned? A picture would be helpful to understand.sagi– sagi2016-05-08 09:27:16 +00:00Commented May 8, 2016 at 9:27
-
1Are you running as a script or as a statement? Do you meam an actual data grid or just neat script output? Is your output just wrapping onto multiple lines per row?Alex Poole– Alex Poole2016-05-08 09:36:28 +00:00Commented May 8, 2016 at 9:36
-
output wrapping on to multiple lines per row but when I do set wrap off now all my inserted lines are gone. I dont see them anymore and the count(*) returns 0. I inserted bunch of rows using @path_to_file.sql in my worksheetuser1870400– user18704002016-05-08 10:35:55 +00:00Commented May 8, 2016 at 10:35
-
Finding no data is nothing to do with wrapping. Are you still in the same session you did the inserts? Did you commit the changes (or roll them back)?Alex Poole– Alex Poole2016-05-08 14:04:40 +00:00Commented May 8, 2016 at 14:04
2 Answers
Sounds like you're getting the script output. You can have that formatted nicely by using SET SQLFORMAT ansiconsole, we'll make the columns line up as nice as possible based on the size of the display.
But if you want the data back in a grid, use Ctrl+Enter or F9 or the first execute button in the toolbar to execute.
This will get you the output in a grid, like this:
I talk about both executing as a script or statement here.
1 Comment
If your issue is with formatting, you may want to look at this link
If your issue is with records not getting inserted, please note these.
- Records inserted in one session will not be visible in another session unless they are committed.
- If you are checking the count in the same session where you inserted the records, then check for errors in insert. Add a show errors command at the end of your script, "path_to_file.sql" to check if any errors occurred while inserting the records.
Hope this helps.


