A database of sorts does seem to be the way to go, but the concept of "database" doesn't automatically imply something as robust as MySQL (which belongs to a class of databases called RDBMS -- Relational DataBase Management Systems).

It looks like what you're interested in is a category of problem called "data serialization" -- storing data structures (usually to disk) for later retrieval. There are plenty of modules to do this, including Storable and DBM::Deep.

Considering that you're trying to learn more about data structures, though, I might suggest you look at one of the human-readable serialization formats, like YAML.

You can serialize data to database systems (even RDBMS) as well, but I'd tackle that separately from learning about managing data structures -- no sense piling your plate too high (do the simplest thing that could possibly work!). When you're ready, you'll want to grab a book or two on Relational theory so that you can design good uses for RDBMS. Then, you'll want to check out the DBI module.

<radiant.matrix>
Ramblings and references
The Code that can be seen is not the true Code
I haven't found a problem yet that can't be solved by a well-placed trebuchet

In reply to Re: MySQL and perl? Or something else? by radiantmatrix
in thread MySQL and perl? Or something else? by Andrew_Levenson

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.