Database fiddle sites
Posted by jpluimers on 2022/10/27
I knew there was JSFiddle for live playing around with JavaScript and more in your browser, so I wondered if there was a similar site for databases and SQL queries.
There are, so here are a few database fiddle sites: SQL playgrounds where you can live play with SQL queries (sometimes even without an underlying example database).
All via [Wayback/Archive.is] database fiddle – Google Search:
- [Wayback/Archive.is] dbfiddle
(
- runs DB2, Firebird, MariaDB, MySQL, Oracle, Postgres, SQLite, SQL Server, Yugabyte, often even multiple versions;
- fiddles with SQL Server 2019 can be created on top of the [Wayback/Archive.is] AdventureWorks sample database;
- fiddles are automatically saved under a GUID URL on first run for easy sharing;
- has a markdown export for embedding into for instance Stack Exchange questions/answers;
- supplied by [Wayback/Archive.is] Expert DBA Help Now;
- a very old version of the back-end source code is at [Wayback/Archive.is] jackdouglas/dbfiddle;
- twitter account is [Wayback/Archive.is] db⟨⟩fiddle (@dbfiddleuk) | Twitter and still active
) which I used for these examples to include in the post tomorrow:
- [Wayback/Archive.is] SQL Server 2019 | dbfiddle:
select a b, c from (values (9, 1, 2), (8, 3, 4), (7, 5, 6)) t(a, b, c) order by b
- [Wayback/Archive.is] SQL Server 2019 | dbfiddle:
select a, b, c from (values (9, 1, 2), (8, 3, 4), (7, 5, 6)) t(a, b, c) order by b
Note the above code makes uses of a [Wayback/Archive.is] Table Value Constructor (Transact-SQL) – SQL Server | Microsoft Docs which has more examples in [Wayback/Archive.is] SQL SERVER – Creating Dataset Using VALUES Clause Without Creating A Table – SQL Authority with Pinal Dave.
- [Wayback/Archive.is] DB Fiddle – SQL Database Playground
(
- supports MySQL, Postgres, SQLite
- supplied by [Wayback/Archive.is] Status200 – Web Application and Digital Product Development (like dbfiddle: also from the UK);
- twitter account is [Archive.is] DB Fiddle (@db_fiddle) | Twitter and is active a few times per year
)
- [Wayback/Archive.is] SQL Fiddle
(
- supports MySQL, Oracle, Postgres, SQLite, SQL Server, with Postgres in two versions;
- requires to create a schema first, which makes it a lot harder to use than the other two;
- runs on insecure http by default;
- according to [Wayback/Archive.is] SQL Fiddle supplied by [Wayback/Archive.is] ZZZ Projects | Adding value to the .NET Community with source code at [Wayback/Archive.is] zzzprojects/sqlfiddle3: New version based on vert.x and docker;
- twitter account is [Archive.is] sqlfiddle (@sqlfiddle) | Twitter, but has not been active since 2018
)
–jeroen
Leave a Reply