Are you also looking for dependencies in SQL manually? Then we go to you! SQL Dynamite, search on base objects

    Hello, dear Habro-readers and SQL-writers. The HostTracker team wants to share a useful utility for SQL developers and administrators.

    What problem are we solving?


    Finding dependencies of objects in the database.
    Search by string in database metadata (stored procedures, View, user functions, table definitions, indexes, keys)



    Where did the idea come from


    My colleague ( fire_lizard ) and I were faced with a huge database, thousands of procedures, tables, functions and other utilities. Refactoring was needed, plus new functionality. With the documentation on the base, everything was not so hot, and we had to deal with the base schema on our own. It was hell.
    In the second week, we realized that we wouldn’t take the bastion abruptly.
    Remembering my glorious Unix past, I started to miss a little grep utility , and we decided that we needed the same, but “without wings” for SQL metadata.

    No sooner said than done.


    The first version was written in a week and fame spread throughout the development department. It was sharpened under MS SQL and worked from the command line.
    Inspired by the feedback from our colleagues, we combed the utility a bit, drew UI for it, highlighted the entries and syntax highlighted. They called SQL Dynamite (just don’t ask why dynamite, it happened ;-)
    Then people began to ask us about supporting other databases. As in any self-respecting large organization, we had a whole zoo of various databases. Following the wishes of the workers, and our own lively interest in SQL, we little by little understood the structure of the schemes of different bases.
    Moreover, during the development process, it became interesting to touch .NET for cross-platform issues. It turned out all is not bad. Having worked a little bit with a file, we made a project under Mono, and the program started working under warm Linux tube and Mac OS X.

    Opportunities


    • Search for entries in the name or text of stored procedures, functions, triggers, tables and indexes, keys;
    • Search using templates (LIKE%, _ syntax);
    • Defining objects to search;
    • Display the body of the found object in the form of DDL;
    • Syntax highlighting
    • Highlighting the found string in the body of the object;
    • Storage of search history;
    • Work with multiple databases.

    Supported DB


    • MS SQL
    • MySql;
    • Oracle
    • SQL Azure
    • Sybase ASE;
    • Sybase Anywhere
    • Ingress
    • PostgreSQL
    • IBM DB / 2;
    • Firebird

    Plans


    • Add DDL save for found objects to file
    • Add ryushechki in UI
    • Do a search on several databases at once
    • Display of found objects in the form of a tree grouped by object type
    • Editing found objects
    • AutoCorrect

    Where to get?


    The latest version is here . Use on health.

    We will be glad to any feedback in the form of comments, criticism and bug reports and the addition of new features.
    PS: If interested, we can write an article about working with meta-information in different databases.

    Also popular now: