SQLike: A simple editor

editor for JSLike

Here's a SQLike editor I wrote. It lets you get your hands dirty with SQLike, the client-side query engine from Thomas Frank.

This started a few weeks back. I read that Thomas had created a nifty DSL in Json for querying (and modifying) arrays of Json. The correct name for it would've been 'JQuery' but that name had already been taken, so he called it SQLike. ;-)

I set about writing a simple editor for it (in the style of the World's Simplest Code Generator) and came up with this fairly usable SQLike editor.

I don't assume you've got any Json to query, and instead expect you to start with a chunk of CSV. I turn that into an array of Json (named 'JsonData') then exec your query over it.

The UI lets you join and query up to two tables at once. I meant to extend it to N tables, but bus-time only lets me do so much, and I keep running into interesting people when I ought to be programming.

editor for JSLike

In my day job I hand write a lot of sql. And with this editor I quickly found that even though SQLike is lighter than XML it's quite 'ceremonious' compared to writing pure SQL.

Apparently Thomas is hoping to making the syntax for SQLike a lot lighter yet, based on comments here including:

"...stop using pipes — the hell with it: reserve a few words :-D..."

...a sentiment I fully agree with. I look forward to any future versions. If you're listening Thomas: keep going! This is an intriguing project!

Also, I want to add I've already found SQLike useful in helping to achieve my day-to-day data-manipulation activities. I can go straight from CSV to 'queries' without having to put the data into a database first.

Sometimes I can't help but picture the future as an endless sea of cubicles, populated by workers struggling to perform data-manipulation duties. And many will continue to get by without any real tools at all. No sql. No sqlike. Not even a wscg or an excel-formula to help them out.

A future "bus project" might be to implement a similar editor for the overlapping project: JsLinq.

Feedback, criticisms, ideas and suggestions always welcome.

 

I'm currently writing a book about how to build your first product. If you want to build your first product, please sign up to be notified when the book is available.

(By the way, I read every comment and often respond.)

Your comment, please?

Your Name
Your Url (optional)
Note: I may edit, reuse or delete your comment. Don't be mean.