in reply to DBI user input question
Any suggestions would be greatly appreciated
See http://perldoc.perl.org/perlintro.html#Conditional-and-looping-constructs especially http://perldoc.perl.org/perlintro.html#while
my $dbh; while( not $dbh ){ my $user = prompt("enter username"); my $pass = prompt("enter password"); $dbh = DBI->connect( $dsn, $user, $pass ); }
See also Term::Interact and Term::Interact example
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: DBI user input question
by edimusrex (Monk) on May 15, 2012 at 12:40 UTC | |
by Corion (Patriarch) on May 15, 2012 at 13:03 UTC |