• Re: mapping an sqlite3 table of files as files on the file system

    From Janis Papanagnou@21:1/5 to Johanne Fairchild on Wed Sep 11 02:43:05 2024
    On 11.09.2024 01:30, Johanne Fairchild wrote:
    Suppose I have a series of text files stored in an sqlite3 table. Can I somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this? It seems to me that I
    would have to.

    An interesting question. - Being curious I searched for "mount sqlite
    on file system" and got a couple links; the first one was https://adamobeng.com/wddbfs-mount-a-sqlite-database-as-a-filesystem/
    Maybe it's of some use. (Or maybe some other links of that search.)

    Janis

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Johanne Fairchild@21:1/5 to All on Tue Sep 10 20:30:01 2024
    Suppose I have a series of text files stored in an sqlite3 table. Can I somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this? It seems to me that I
    would have to.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Lawrence D'Oliveiro@21:1/5 to Johanne Fairchild on Tue Sep 10 23:38:36 2024
    On Tue, 10 Sep 2024 20:30:01 -0300, Johanne Fairchild wrote:

    Suppose I have a series of text files stored in an sqlite3 table. Can I somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this?

    You could do something via FUSE. That allows you to implement your code entirely as a userland process.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Muttley@dastardlyhq.com@21:1/5 to All on Wed Sep 11 07:11:48 2024
    On Wed, 11 Sep 2024 02:43:05 +0200
    Janis Papanagnou <janis_papanagnou+ng@hotmail.com> boringly babbled:
    On 11.09.2024 01:30, Johanne Fairchild wrote:
    Suppose I have a series of text files stored in an sqlite3 table. Can I
    somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this? It seems to me that I
    would have to.

    An interesting question. - Being curious I searched for "mount sqlite
    on file system" and got a couple links; the first one was >https://adamobeng.com/wddbfs-mount-a-sqlite-database-as-a-filesystem/
    Maybe it's of some use. (Or maybe some other links of that search.)

    Don't see how you interact with it using any of the normal toolset unless you map table -> directory and column -> file though it would be a very clunky
    and inefficient way to use a relational DB.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Kenny McCormack@21:1/5 to Muttley@dastardlyhq.com on Wed Sep 11 11:13:13 2024
    In article <vbrfrk$3fo3f$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: >On Wed, 11 Sep 2024 02:43:05 +0200
    Janis Papanagnou <janis_papanagnou+ng@hotmail.com> boringly babbled:
    On 11.09.2024 01:30, Johanne Fairchild wrote:
    Suppose I have a series of text files stored in an sqlite3 table. Can I >>> somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this? It seems to me that I
    would have to.

    An interesting question. - Being curious I searched for "mount sqlite
    on file system" and got a couple links; the first one was >>https://adamobeng.com/wddbfs-mount-a-sqlite-database-as-a-filesystem/
    Maybe it's of some use. (Or maybe some other links of that search.)

    Don't see how you interact with it using any of the normal toolset unless you >map table -> directory and column -> file though it would be a very clunky >and inefficient way to use a relational DB.

    I can't quite tell from your post whether or not you actually read the link given above. I just did and (tl;dr) basically agree with you that it looks clunky, but I suppose that a) It is intended as proof-of-concept and b)
    It's the sort of thing that appeals to people who like "Everything is a web app" kind of thinking. I'm guessing that neither you nor I fall into that classification.

    That said, it looks like it is a two-step process:

    1) You run his little utility - which is, of course, a black box to
    most of us. It looks like it is written in Python, so it would be,
    in theory at least, readable/understandable as-is. I.e., don't
    need to go looking around for the source.

    2) Then you "mount" it ("it" being the output of the previous step)
    somewhere on the filesystem, and then you get what you want.

    The details of step 2 are not specified; you are expected to already know
    all about how that stuff (mounting "WebDAV" thingies) works already.

    So, all in all, probably not of much use to either you or I.

    --
    Treating the stock market indexes as general measures of the well-being of a society is like treating your blood pressure as an indicator of health. The higher, the better, right? In fact, a high stock market is good for the investor
    class, but it means the rest of us are getting screwed better than ever.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Muttley@dastardlyhq.com@21:1/5 to All on Wed Sep 11 12:25:32 2024
    On Wed, 11 Sep 2024 11:13:13 -0000 (UTC)
    gazelle@shell.xmission.com (Kenny McCormack) boringly babbled:
    In article <vbrfrk$3fo3f$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: >>On Wed, 11 Sep 2024 02:43:05 +0200
    Janis Papanagnou <janis_papanagnou+ng@hotmail.com> boringly babbled:
    On 11.09.2024 01:30, Johanne Fairchild wrote:
    Suppose I have a series of text files stored in an sqlite3 table. Can I >>>> somehow read these files as if they're files on a certain directory?
    Would I have to write a kernel driver for this? It seems to me that I >>>> would have to.

    An interesting question. - Being curious I searched for "mount sqlite
    on file system" and got a couple links; the first one was >>>https://adamobeng.com/wddbfs-mount-a-sqlite-database-as-a-filesystem/ >>>Maybe it's of some use. (Or maybe some other links of that search.)

    Don't see how you interact with it using any of the normal toolset unless you >>map table -> directory and column -> file though it would be a very clunky >>and inefficient way to use a relational DB.

    I can't quite tell from your post whether or not you actually read the link >given above. I just did and (tl;dr) basically agree with you that it looks

    I did but I've never used sqllite so I don't know what the json , tsv etc files signify.

    clunky, but I suppose that a) It is intended as proof-of-concept and b)
    It's the sort of thing that appeals to people who like "Everything is a web >app" kind of thinking. I'm guessing that neither you nor I fall into that

    Yes, simple text or binary protocols seem to have gone out the window. Why bother writing a few hundred lines of C client-server socket code when you can waste time, resources and CPU cycles setting up a bloated web server in a docker container and pass your data over http with all the back end nonsense that entails getting and parsing it.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)