Community
    • Login

    SQL Formatter Plugin SQLinForm has now Visual NAvigator for complex SQL

    Scheduled Pinned Locked Moved Notepad++ & Plugin Development
    4 Posts 3 Posters 115 Views 3 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Guido ThelenG Offline
      Guido Thelen
      last edited by Guido Thelen

      Hello, just wanted to let you know that SQLinForm got a fresh new function

      The new version of the SQLinForm plugin adds a Navigator, a docked side panel that shows the structure of your SQL. It’s meant for long scripts, stored procedures and deeply nested queries.

      What it does

      • Overview graph: every statement and sub-SQL as a box. Boxes are colored by type: SELECT, INSERT, UPDATE, DELETE and MERGE. Edges are labeled with the clause the sub-SQL sits in (WHERE, SET, USING, UNION ALL, …), and CTEs are labeled with their names (WITH region_sales).
      • Structure tree: each statement broken down into clauses and items, with quick facts like 3 columns · 2 tables · 1 condition · 1 sub-SQL.
      • Click to jump: click a box or a row and the line is selected in the editor.
      • Levels 1–4 / All: collapse or expand the whole tree in one click.
      • Search with next/previous hit, highlighted in both the tree and the graph.
      • Cursors, CTEs (with the main query shown separately), UNION, MERGE … WHEN and INSERT … SELECT are handled.
      • Light and dark theme. The UI is available in 12 languages.

      I appreciate any suggestion or error feedback :-)

      navigator2.png
      structviewer.png

      PeterJonesP 1 Reply Last reply Reply Quote 4
      • PeterJonesP Offline
        PeterJones @Guido Thelen
        last edited by

        @Guido-Thelen ,

        I don’t use SQL (nor thus your plugin), but from what little I know about it, the screenshot of your new Navigator feature looks like an impressive amount of work.

        Out of curiosity, do other SQL editors/interfaces give you that amount of help? Or has your plugin just become the premier SQL development tool? :-)

        Lycan ThropeL 1 Reply Last reply Reply Quote 2
        • Lycan ThropeL Offline
          Lycan Thrope @PeterJones
          last edited by Lycan Thrope

          @PeterJones ,
          It appears that it’s a diagrammer, which should help visually see what’s going on, especially when the SQL statement gets complicated.

          dBASE has a different tool, that allows us to click on tables, set sorts…etc that creates a SQL statement, without knowing SQL itself as long as you know what operations you want done on the data, the tool, SQL Builder will write the SQL, albeit it’s a subset for dBASE called LocalSQL.

          There’s similar capability in MySQL Workbench, that let’s one diagrammatically visualize and create their entire database’s structures, and visually link and set operations.

          SQLinForm’s new feature, is a nice tool for a text editor to have, if one wants to diagnose a complex SQL statement that may not be doing what someone wants it to do, breaking down visually the different steps and dependencies that are being used by the statement at different points. I’d say it looks like it does a good job of documenting the SQL code as well. I guess the one thing I’d ask, is does it stay only with Standard SQL or does it see and interpret variants? (MySQL, PostgreSQL, Oracle, and other popular dialects.)

          1 Reply Last reply Reply Quote 2
          • Guido ThelenG Offline
            Guido Thelen
            last edited by

            @PeterJones, thanks! It was indeed a fair amount of work. To your question: database IDEs like DataGrip, DBeaver, SSMS or MySQL Workbench do offer visual help, but mostly in a different direction. They show execution plans (how the database runs a query) or let you build queries visually, and they usually need a live database connection.

            My motivation came from my own work in data warehouse projects. It’s not unusual there to inherit SQL statements spanning several pages, undocumented and unformatted. My first step was always to format them, which already helps a lot to understand what’s going on. The Navigator is the next step: a visual map of the structure, especially for those “monster SQL statements”, right inside the editor, with no database connection needed. “Premier SQL development tool” is a bit much :-) but for reading and understanding large SQL in Notepad++ it should help a lot.

            @Lycan-Thrope, good description, that’s exactly the idea: understanding and documenting an existing statement rather than generating one. And no, it isn’t limited to Standard SQL. The Navigator visualizes the result of the formatter, so it works with every dialect the formatter supports (30+, including MySQL, PostgreSQL, Oracle, SQL Server, DB2, Snowflake and more). For now it shows SQL statements and DDL. If you run into a statement it doesn’t break down correctly, I’d be glad to get a sample.

            1 Reply Last reply Reply Quote 2

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • First post
              Last post
            The Community of users of the Notepad++ text editor.
            Powered by NodeBB | Contributors