Oracle SQL Developer v4.0: Breadcrumbs

thatjeffsmith SQL Developer 14 Comments

Tell Others About This Story:

Hansel and Gretel are in the forest and don’t want to get lost, so Gretel leaves a trail of white pebbles to mark their way. In future adaptations of this Bros. Grimm story, the white pebbles have become ‘breadcrumbs.’

So what does this have to do with SQL Developer?

When working with large bits of PL/SQL code, you now have what we are calling breadcrumbs in the editor footer space. Now in the the world of web design, breadcrumbs have also been used to show the navigation path of your web session. This is a bit different, but I think you’ll get the gist once you see it for yourself.

PL/SQL Editor 'Breadcrumbs'

PL/SQL Editor ‘Breadcrumbs’

The indicator shows where you are in your code block. You can also click on the breadcrumb to navigate back to the beginning of said block. If I were to click on the ‘Generate_OS_File’ bit, that will take me back to the first line of that procedure.

If I were to click on the first bit of the breadcrumb, it will show a ‘table of contents’ of sorts that I can use to navigate to anywhere in the package.

Where do I want to go next?

Where do I want to go next?

The editor will show you in a loop, if statement, exception, etc. If you can’t remember or tell where you’re at inside a large code block, this feature should help you out a bit.

I'm in this package, this procedure, this exception block, and this if statement...

I’m in this package, this procedure, this exception block, and this if statement…

Special thanks to @martindsouza for today’s post idea.

Related Posts Plugin for WordPress, Blogger...
Tell Others About This Story:

Comments 14

  1. Hi Jeff,

    I recently downloaded SQL developer version 4.2.0.16.260.1303.
    The “Show Breadcrumbs” checkbox is ticked but no breadcrumb is shown in the code editor.

    Is there another setting to change in order to display the breadcrumb?

    Cheers,
    Paul

    1. thatjeffsmith Post
      Author
  2. Version 4.1.0.19 (Java: 1.8.0_45)

    Preferences -> Code Editor -> Display -> Show Breadcrumbs:

    The setting doesn’t seem to have an effect: it never shows the breadcrumbs in the editor.

  3. Hi, Jeff.

    I’m making the procedures and functions on the Oracle SQL Developer.

    Now, when I open the package body editor, the status bar always saying…
    “calculating the breadcrumbs for …” and some times later hanging.

    What is the reason of this strange?

    Thanks.
    Regards,

    Weipeng

    1. thatjeffsmith Post
      Author
  4. Is there some dba view or something that you need access to for the breadcrumbs to work. I am using 4.1.0.18 and it never finishes calculating breadcrumbs. The progress bar never goes away. I figured maybe there is something my user cannot see in the db.

    1. thatjeffsmith Post
      Author

      I don’t think that’s it…unless you’re seeing it for EVERY pl/sql object you open. We had this in the 4.0 code base, and logged (and killed) a few bugs against it. If you can share your sample code, we can try to take a look at it. You can also go into preferences and disable ‘Show breadcrumbs’ under the Code Editor and Display page.

    2. thatjeffsmith Post
      Author

      If you think it’s privilege based, go to View > Log, and observe the Statements panel. You can see any queries fired off to the data dictionary when you open/compile your code.

      1. Thanks for the feedback! For some reason, it’s working now. I know for a few days that it wasn’t. The View>Log suggestion was very helpful however, I didn’t realize that was there. Thanks again.

  5. Hi Jeff,

    Does this feature need to be enabled? When I start to edit a package the first “crumb” appears as per your example above, but then clicking on that crumb does nothing thereafter.

    I’m using V4.0.0.12.27 and JDK 1.7.0_25 (both 64 bit).

    Also in the last version of SQL Developer, double clicking on a function or procedure name in the connection tree on the left used to take you directly to that code. It doesn’t work any more. Is that an intentional change in V4?

    Cheers,

    Steve

    1. thatjeffsmith Post
      Author
      1. Hi Jeff,

        Thanks for the feedback.

        I did some tests in a few of our DB instances and found it does work for most packages, but not all.

        Some that do not work for me and are available to download include JSON_PARSER and JSON_PRINTER that come with PL/JSON which is available to download from http://sourceforge.net/projects/pljson/

        When invoking the editor for the package body of these packages, the first breadcrumb appears at the bottom left, but nothing happens when it is clicked. This occurs with one or two of our custom packages as well.

        Hope that provides enough to recreate the issue.

        Cheers,

        Steve

Leave a Reply

Your email address will not be published. Required fields are marked *