Only to add my 2 cents worth. If you are looking at storing perl data structures with unknown lengths. Modules such as
will convert a perl data structure such as an array or a hash or any mixture thereof in a format that you can import back into your program from the database. These modules turn a structure into a simple text format which can be easily stored and retrieved from any RDBMS.