in reply to DBI database connection support and more

and let me know how you feel database connections should be cataloged

I don't think that there is "a" way. Depends on your application. Treating the DBI specific configuration information separately from the rest of your applications configuration options seems counterproductive to me

I usually put DBI info wherever the rest of the applications configuration information lives. A YAML file has been a recent popular choice.

Using the environment variables DBI_DSN, DBI_USER and DBI_PASS can be another useful way of passing the info in - and has the advantage of being built into DBI.

  • Comment on Re: DBI database connection support and more

Replies are listed 'Best First'.
Re: Re: DBI database connection support and more
by princepawn (Parson) on Sep 18, 2003 at 21:43 UTC
    Using the environment variables DBI_DSN, DBI_USER and DBI_PASS can be another useful way of passing the info in - and has the advantage of being built into DBI.
    Yeah it certainly depends on the situation... I live in a garden of databases here... Sybase, MySQL and SQL2000... also , we have several databases on each of these whose logical information is the same (name, id, address ,email, etc...) but whose concrete field name varies. So I need to warehouse connections and table field names.

    YAML was attractive to me but I would rather just pure Perl as I know the syntax and have had the parser flat out break without good error reporting on some .yml trial files of mine.

    Carter's compass: I know I'm on the right track when by deleting something, I'm adding functionality.

      Did you file bugs for those YAML defects? I'd like to see those files.