Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Perl Modules

    DBIx::Config 0.000002

    Download button

    No screenshots available
    Downloads: 52  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    symkat | More programs
    Perl Artistic License / FREE
    September 19th, 2012, 02:45 GMT
    ROOT / Programming / Perl Modules

     Read user reviews (0)  Refer to a friend  Subscribe

    DBIx::Config description

    Manage DBI credentials

    DBIx::Config is a Perl wrapper around DBI to allow you to simply load database credentials from a file.

    SYNOPSIS

    Given the like /etc/dbi.yaml, which contains:

     MY_DATABASE:
     dsn: "dbi:Pg:host=localhost;database=blog"
     user: "TheDoctor"
     password: "dnoPydoleM"
     TraceLevel: 1


    The following code would allow you to connect the database:

     #!/usr/bin/perl
     use warnings;
     use strict;
     use DBIx::Config;


     my $dbh = DBIx::Config->connect( "MY_DATABASE" );

    Of course, backwards compatibility is kept, so the following would also work:

     #!/usr/bin/perl
     use warnings;
     use strict;
     use DBIx::Config;

     my $dbh = DBIx::Config->connect(
     "dbi:Pg:host=localhost;database=blog",
     "TheDoctor",
     "dnoPydoleM",
     {
     TraceLevel => 1,
     },
     );


    For cases where you may use something like DBIx::Connector, a method is provided that will simply return the connection credentials:

     !/usr/bin/perl
     use warnings;
     use strict;
     use DBIx::Connector;
     use DBIx::Config;

     my $conn = DBIx::Connector->new(DBIx::Config->connect_info("MY_DATABASE"));



    Product's homepage

    Requirements:

    · Perl

      


    TAGS:

    DBI credentials | credentials manager | Perl module | Perl | DBI | credentials

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM