Friday, July 11, 2014

Creating SQL database `on the fly` -

Recently I had to write some SQL queries in a quite advanced application (Banshee [1]). I'm not an expert in SQL, so I had to work through trial and error. But recompilation and restart application every time, when I changed something, was very time consuming. Unfortunately, I didn't use my own computer, and I hadn't installed(and I wasn't able to install) any SQLite shell. I started to looking for web interface for SQLite database.
One of the first result in Google was sqlfiddle [2] page. At first sight website looks very simple. And in reality - it is. On the left side you have to write DDL statements, and on the right side, you may use created schema by sending some queries.
For now, service offers many different databases:
  • MySQL (a few versions)
  • Oracle
  • PostgreSQL (a few versions)
  • SQLite
  • MS SQL Server (a few versions)
You may also generate link to your case, and paste id e.g. in some forum or irc channel.
There is also a lot of minor features, which can be use
ful in specified cases:
  • 3 types of displaying results,
  • execution time measurement,
  • query execution plan,
  • different query terminators,
and many others, which I probably missed. I would highly recommend at least try this tool. Maybe you would like it, and will use it in your daily work ;)

sqlfiddle in action


No comments:

Post a Comment