Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: RFC: Fuse::DBI - mount database as filesystem

by cchampion (Curate)
on Oct 09, 2004 at 08:44 UTC ( #397845=note: print w/ replies, xml ) Need Help??


in reply to RFC: Fuse::DBI - mount database as filesystem

DBIx::FileSystem does something very similar to what you say.

Be aware that both systems fail for the very same reason, i.e. that tables aren't files.

Information in relational database tables often does not make sense unless it is taken together with information in other tables with complex joins and search conditions.

Ancient hierarchical databases could have this one-to-one similarity, but they failed because searching through them was only available in predefined directions, while relational DBMS systems allow greater flexibility.

Even if you find a way of reducing complex queries to a simple file interface, so that I can see a financial report as a file and edit it with Vi, such interface would need to have several well written queries in the background, and this leaves us with the same dilemma we had with hierarchical databases, i.e. without a pre-defined path, we can't have an answer to our questions.

I'd rather write my own queries in Vim and use a sensible script to fetch the results.


Comment on Re: RFC: Fuse::DBI - mount database as filesystem
Re^2: RFC: Fuse::DBI - mount database as filesystem
by dpavlin (Friar) on Oct 09, 2004 at 14:20 UTC

    I also think that KISS principle is best. So, as noted before, this module doesn't try to export complex relations in database. User have to create queries to export just part of database in which he or she is interested (good example included in distribution is WebGUI script which exports just templates). It's very much like vim script that you refer to (which is very useful if you just want to edit data using vim, ++ for that).

    But, having part of database as filesystem allows you to use all filesystem utilities like grep, cp (rm and mv are not supported at the moment) as well as different editors, ftp or http servers and so on. You can even create tar of your data before you start to edit it, just as backup.


    2share!2flame...

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://397845]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (9)
As of 2014-10-21 22:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (112 votes), past polls