J
Justin C
My program connects to a database, and is to insert a row into a table.
It runs with no errors or warnings but the database is not updated.
There is nothing in the Postgresql log either.
Here is the code, it's a small as I can make it:
#!/usr/bin/perl
use warnings ;
use strict ;
use DBIx::Simple ;
use SQL::Abstract ;
my $user = "[user]" ;
my $password = "[passwd]" ;
my $dataSource = DBIx::Simple->connect(
'dbig:database=prospects', $user, $password,
{ RaiseError => 1 , AutoCommit => 0 }
) or die DBI::Simple->error ;
my %input = (
"key" => "4",
"contact" => "john",
"co_name" => "John's Fluff and Grime Ltd",
"ad1" => "1 Some Road",
"town" => "BENJY",
"p_code" => "BN1",
"county" => "Middleshire",
"tel1" => "01234 567234",
);
$dataSource->insert('prospect', \%input);
--- END ---
That last line is taken directly from
<URL: http://search.cpan.org/~juerd/DBIx-...mple/Examples.pod#EXAMPLES_WITH_SQL::Abstract>
(except, on the above page they have $db->insert...)
Any suggestions of where to start looking?
Justin.
It runs with no errors or warnings but the database is not updated.
There is nothing in the Postgresql log either.
Here is the code, it's a small as I can make it:
#!/usr/bin/perl
use warnings ;
use strict ;
use DBIx::Simple ;
use SQL::Abstract ;
my $user = "[user]" ;
my $password = "[passwd]" ;
my $dataSource = DBIx::Simple->connect(
'dbig:database=prospects', $user, $password,
{ RaiseError => 1 , AutoCommit => 0 }
) or die DBI::Simple->error ;
my %input = (
"key" => "4",
"contact" => "john",
"co_name" => "John's Fluff and Grime Ltd",
"ad1" => "1 Some Road",
"town" => "BENJY",
"p_code" => "BN1",
"county" => "Middleshire",
"tel1" => "01234 567234",
);
$dataSource->insert('prospect', \%input);
--- END ---
That last line is taken directly from
<URL: http://search.cpan.org/~juerd/DBIx-...mple/Examples.pod#EXAMPLES_WITH_SQL::Abstract>
(except, on the above page they have $db->insert...)
Any suggestions of where to start looking?
Justin.