Hi,
i think that this is the problem. however i can't work out how to use the suggestion on my script,
i have done this,
#!/usr/bin/perl
use CGI::Carp qw(fatalsToBrowser);
use DBI;
print "Content-type: text/html\n\n";
my $dbs = "DBI:ODBC:DRIVER={SQL Server};SERVER={dmssql01};DATABASE={sa
+ge200_dmstestconversion}";
my ($username, $password) = ('user', 'passwd');
my $dbh = DBI->connect($dbs, $username, $password) or die "$DBI::errst
+r\n";
my $sth = $dbh->prepare( 'backup database Sage200_DMSTestConversion to
+ DISK = \'d:\sage\sage200data\sagebackup2.bak\' ;') or die "Couldn't
+prepare statement: " . $dbh->errstr;
$sth->execute() or die "execute failed: " . $sth->errstr();
do {
while (my @row = $sth->fetchrow_array()) {
print "backing up,<br>";
print @row;
}
} while ($sth->{odbc_more_results});
my @error = $sth->err;
print @error;
$sth->finish();
$dbh->disconnect();
print "Backup Completed";
This still gives me the same output to screen and doesn't backup.
Thanks