lobotomy
LOBOTOMY PROJECT

synapse
SYNAPSE PROJECT

Graphical SQL
(v0.2, 3.9.2006)



Abstract
Working on Synapse is a singular tasks: his target is to permit a user-friendly interface to the Hyppocampus relational filesystem, which instead works with SQL queries that are incomprehensible for most of non-techical folks. At the other hand, it is a filemanager, and is not so easy to convert a SQL set, composed by more data in a tabular form, in a simple grid of icons. We aim to create a particular kind of visual SQL frontend, and, why not, to do it with style...



Summary:

Introduction
Most of people who will read this documents know SQL, its statements and its keywords, but most of people who (I hope!) will use Hyppocampus not. Synapse borns to be a filemanager designed around this particular filesystem, or, better, to be an intuitive interface to this particular relational database. It is not a simple task, just because it imply the definition of a new paradigm of file management.
Before to start, a brief parenthesis about the general approch that wants to be the basis for the design of Synapse, and a rule to remember while placing items in the window: SQL is a limited set of statements, but different arrangement of them cause different results, and the number of possible dispositions is enormous. Is not possible to place in the interface buttons and widgets that refere to each possible disposition of statements in the query; is not possible to hope the user learn to write itself his query; is not acceptable to limit the potentials introduced by the availability of the relational platform to a few clickable elements. So the wish is to create a mutable interface, with hidden buttons that are inserted into the contextual menus or in the taskbar only when needed, and to cut down all unnecessary features to have, finally, the most clean and powerful (and, perhaps, beautiful) compromise between usability and accessibility to the data.
Follows a summary of many techiques and workarounds studied to resolve some of the problems introduced by the need to handle SQL statement in a graphical environment, as to generate complex SQL queries with a few clicks of the mouse.

Columns Handling
SELECT foo, bar WHERE baz = 'string';
Until the user select one only parameter to identify the file in the window is simple to rappresent, we just assign to the icon the relative value as label, but how to list more metadata showing a single icon with an as short as possible label?
The easiest way is to build the label as a common list of words comma separated, but of course it is acceptable until we have a pair of values to show.
The second option is to exploit the graphical environment to improve the visual grouping of different metadata assigned to the single file: as in Nautilus, the Gnome's filemanager, we can put little emblems all around the icon, but, not as in that application, emblems aren't user defined but placed by the filemanager itself to indicate the assignation of a certain value for a certain metadata to the file. This method can be used to rappresents all those metadata which available values are summarized in a fixed enumeration: text, video and audio encoding type, target system architecture for binaries, permissions (at last, there are "only" 2^9 available dispositions for the canonical Unix permissions bits), but also mimetypes and, assigning an avatar to each user in the system, the owner for the file.

Columns Handling

ORDER BY
SELECT foo WHERE bar = 'string' ORDER BY baz;
Of course, order icons by a particular parameter, such as the name or the creation date, is an easy task. But we can go beyond the simple arrangement of elements in the icon view: putting an item in the contextual menu of each file we can provide the ability to sort all elements by every metadata assigned to them, also starting from a specific value and limiting the results to a defined number of items, without explicitly write a new query and without populate the interface of a number of button doing all the same thing. For each metadata, sorting will be available in ascending and descenting order, and including more main parameters too.

Columns Handling

GROUP BY
SELECT foo WHERE bar = 'string' GROUP BY baz;
One of SQL statements that don't have a corrispective in the file management context is "GROUP BY". We can interprete it as a folders rappresentation, but we prefer to not to use the folders abstraction in Synapse just because it is a way to hide contents that can be showed all together in the same shot, and closely remember the hierarchical tree-structured filesystem.
The idea is to create a new form of icon view, where items in the same group are showed as a stack. This is not an original innovation: more graphical interfaces have been implemented the icon piles (the last is the BumpTop 3D desktop, which videos shared across the Net a few months ago surprised the folks): as in some of them, in Synapse also these elements are a temporary arrangement for items, an escamotage to visualize the concept of a group. These stacks will be unfoldable (to show and made accessible the lower items) and singularly sortable and partially whole editable for adding and remove metadata to every component.
To better arrange items on screen, each group would will be arranged in an new window, so to be better editable and whole visible and readable.

Columns Handling

SQL Generation
One of main goals for the Synapse design is the automatic generation of SQL queries to access the filesystem: populating the interface of aimed, full specialized (and discrete) buttons the user can be driven throught all possibility offered by the relational platform, without limit (too) its freedom to navigate contents and advanced combination of SQL statements.
One of most obvious approch with this scope is to permit to immediately access to all elements that share a particular value to a particular metadata (or more of them) assigned to a file, just adding a submenu in the contextual menu linked to each icon.

SQL Editor
One of most essential and at the same time complex elements that must be attached to Synapse is an intuitive editor to build SQL queries to submit to the filesystem: essential because not everything can be summarized in a particular button that generate the SQL code and the human intervent is indispensable to access to most exotic data relationship, complex because is not an easy work to design a single panel that permits to define each available parameter for the final submition and intuitive enough to be used by the domestic user.
The first example of this kind of tool is included in the 0.1 release of Synapse: it don't permits particulary efficient compositions, but already is intricated enough to discourage the common user to use it.

Links


Copyright © 2006 - Roberto -MadBob- Guido