Are there any tools to visualize a complicated SQL join? [closed] - sql

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Given that many frameworks will create complicated (and maybe not so readable/logical) SQL queries, it would seem that having a tool to show, visually, how the joins were done might be a helpful tool. But I have not found such a tool.
I took a query that included a lot of tables and created a graphic as an example of what I think would be the output from such a tool:
The text on the links are the field names that are used in the join. The bold items are inputs to the query. The table names ending in digits are just repeat instances of the same table (ie Partner and Partner2 are the same table, just part of the query more than once).
I would like to be able to drop an SQL query into a tool and see a diagram like this. Possible?

I found this tool, it might be useful.
http://queryviz.com/online/
Although the SQL syntax supported looks to be quite limited..

You can get this sort of output using SQL Analyzer with SQL Server. Something similar exists for postgresql: I've never seen anything graphical for MySql or Oracle.
In other words: nothing generic (which is perhaps what one would expect given the complex and individual nature of database optimizer engines).

Related

What are some SQL clients with a graphical query designer..? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Another user asked the similar question, What are the query browsers for DB2?.
But I would like to ask: what are some SQL browsers with a graphical query designer? Like the other user, I'm also using DB2, but most generic or open-source clients can connect to any SQL server, so I'll assume if there are any with a GQD, I'll be able to use it with DB2.
The vintage of our DB2 server and AS400 is v5/v6 and unlikely to be upgraded any time soon, and I find the included IBM SQL client to be primitive to the point of useless. The other clients I've tried are DBeaver, Toad, and Squirrel. I got DBeaver to work with our server, but other two I could not (yet). It's very nice and I'm happy to stick with it, but alas it does not have a GQD.
I understand many DBAs feel a GQD is an impediment to advanced query design, and I agree. However, it can be a useful tool for visualizing and building sub-sections of large queries, especially joins and weird logic. I find the most useful method is to design some or all of a query graphically, and then switch to pure SQL and clean it up.
Check out AQT Advanced Query Tool
It has a graphical query builder and can be recommended - it supports Db2 for iSeries

Ready web query interface to SQL databases [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Do you know any free tool which would constitute a web-based SQL database generic query interface, incl.:
(mainly) allowing to type in an SQL query and display the result in some nice way
the interface should allow for some basic security - allowing only SELECT queries
the very need is to support MS SQL Server, but Oracle support would be useful
should run against an existing database instance without any re-configuration needed
might be simple, no need to browse tables, analyze database columns or anything else you would experience in SQLDeveloper or SQL Server Management Studio
Platform / language / etc. is of second importance.
The StackExchange Data Explorer has this functionality (example) and it is open source, so you may be able to just install and make use of it, or even extract the relevant code.
Perhaps something like the SQL Fiddle?
Obviously, this is mainly for demonstration purposes - it won't help you if you want to install it on top of your own database.
Re:dash (Redash) is a promising new open-source player on the market. From their own website:
re:dash is our take on freeing the data within our company in a way
that will better fit our culture and usage patterns.
Prior to re:dash, we tried to use traditional BI suites and discovered
a set of bloated, technically challenged and slow tools/flows. What we
were looking for was a more hacker'ish way to look at data, so we
built one.

Freeware Query Builder [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I'm looking for some freeware Query Builder.
Query Builder in Aqua Data Studio allows you to visually build queries:
select the column you want returned
generates joins for you(you just select by which columns you want to join it)
Good question! I thought there were many DB tools that fit your description, but when I checked a commonly-sourced Wikipedia article (see comment below), I found that most free/open source DB management software does not have a visual query builder feature! (I build my queries from scratch, so this is not a feature I particularly need.)
The freeware version of Toad for Data Analysts is a good bet. You can download and use it for 120 days. After that time, you need to reinstall on your PC. You might need to check to see if you will get write-access to non-Oracle databases, but I do know you can at least get read access to most non-Oracle DBs.
You might also like SQL Developer, which has a more robust community of users than that of the Freeware Toad for Data Analysts. That will only give you read-only access to certain non-Oracle databases.

How to document database efficiently (tables, attributes with definition)? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
We have a fairly large database (in SQL Server 2008) with many tables. We have just bought Red Gate's SQL Doc for documentation purposes. We would like to document this database in a detailed way. What is the best practice in documenting a database? How do you document your attributes with definitions? SQL Doc documents the database nicely but how to add attribute definitions to this document (is there some automagigal way)?
We use extended properties to "tag" constraints, tables, indexes, viws, procs, the lot. (we also use SQL doc)
It's mentioned on the interweb quite a lot too
I don't know of any automatic ways of doing this, it's a bit tedious, but worth it. There are a few ways to do this, one through the table designer (right clicking on a table, and choosing "design") and entering text into the "Description" property on each column, or you can also use the Database Diagramming Tool as described here:
http://devtoolshed.com/content/sql-create-table-add-description-column
You should check out this question on how to add a description to a column.
adding a column description
This way when you run your update scripts you can add descriptions to columns or tables with the extended properties that GBN mentioned

Tool for comparison of SQL Server query plans? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Does anyone know of a tool that can be used to compare (relatively complex) query plans? I'm not looking for a guide to query plans, but just a tool that enables me to quickly see e.g. the different index use.
EDIT: just to make it clear, I'm not looking for information about the plan, but a tool that can quickly point out the differences between two plans (I know, I could do that myself, but the size of the plan(s) make that difficult).
I'm not aware of a ready-made tool for this, just if you use SET SHOWPLAN_XML ON to get the plans in XML format you can pretty-format them in Visual Studio, and then compare with your favourite text comparison tool.
And you can also right click on the plan in SSMS and choose Save Execution Plan as... to save to a file.
There is a tool called PICASSO - http://dsl.serc.iisc.ernet.in/projects/PICASSO/index.html which has an option to compare 2 query plans, provided the queries are the same but with different selectivities.
The to generate the plan differences can be used in your case as it is freely available.
I find that SQL Sentry Plan Explorer (free) is a useful tool analyzing queries, and also comparing them, as highlighted in this blog post.
I generally just compare execution plans with a text compare tool - I also find that for complex plans its useful to look at the raw Xml of the plan just for the ability to search for an index / table to see where it appears in the plan.