boftx:

To me, it depends on the "kind" of application. If the database would best used by everyone, I'd prefer a common data area (such as /var or C:/Program Data/ or equivalent. If it's an application where every user would want their own copy, I'd probably prompt the user for their preferred location (I have the same aversion to applications cluttering up my personal work area with directories and files of their own). Leaving the default as the personal work area could be fine, so long as it's easy to override and/or change, so I'm not stuck with it.

I'd avoid putting the database in the same directory with the module, though. There may be some good arguments for it, but I've not seen a case where I'd consider it. Generally, I don't back up my OS and App directories, but I *do* back up my user and data directories. I don't back up the OS and App stuff since I can simply reinstall it. But it would suck if I couldn't retain my data without specifically choosing to back up a particular App directory.

That's my $0.02, take it for what it's worth...

...roboticus

When your only tool is a hammer, all problems look like your thumb.


In reply to Re: Where to put an application database? by roboticus
in thread Where to put an application database? by boftx

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.