in reply to Re: Text storage/retrieval
in thread Text storage/retrieval

One aspect is the maintainability - it wouöd be great if the data could be stored in csv files or such. Any idea on that?

Replies are listed 'Best First'.
Re^3: Text storage/retrieval
by BrowserUk (Patriarch) on Mar 05, 2012 at 13:39 UTC

    I see little difference in maintainablility between:

    ( "The quick", "brown fox", "jumps over", "the lazy", "dog", );

    And:

    "The quick", "brown fox", "jumps over", "the lazy", "dog"

    But if you do, you could do the same thing -- put each language into a separate csv file -- and do:

    my @text = someCSVparser( "$lang.csv" ); ...

    It'll be slower, but for 1500 strings, probably not enough to worry about.

    If performance is a concern -- as it seemed from your OP -- then you could store the texts in .csv files and use an off-line process to create the Storable form from them whenever they change. It has the advantage of ensuring that if the storable format shoudl ever change in incompatible ways -- it has happened in the past -- then you have the sources to fall back on.


    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

    The start of some sanity?