Your windows program Cannot Find File at Startup - The way to Resolve This kind of Error Message?
Leave a comment!
Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.
Be nice. Keep it clean. Stay on topic. No spam.
Name (required)
Mail (will not be published) (required)
Website (optional)
You can use these tags:<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>
This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.
Comment spam protected by SpamBam
(17533 spam filtered)
pr wrote:
> Overview:
>
> Using perl+DBI+DBD::ODBC on Windows, I am connecting to a SQL Server 2005 instance and issuing a "restore database from disk='c:\foo-backup.bak'".
>
> The restore attempt appears to succeed, and nothing calls my installed error handler.
>
> However, if I run a trace on the SQL Server, I can see the restore is throwing an error:
>
> Error 3224, Severity 16, State 1: Cannot create worker thread.
> RESTORE DATABASE is terminating abnormally.
>
> If I write the same SQL to a file, then execute the file via sqlcmd, the restore works as expected. Hence I am confident in the SQL command as well as the backup file.
>
> Other DML-type commands work as advertised, as does the error handler. It seems to be something specifically about a restore.
>
>
> Specifics:
>
> The version of perl is ActiveState's v5.10.0 running on a 32 bit Windows 2003 server.
>
> My DSN and connect code looks like:
>
> my $dsn = 'Driver={SQL Native Client};Server=myServer;Database=master;Trusted_Connection=yes;Encrypt=yes;';
> my $dbh = DBI->connect("dbi:ODBC:$dsn",'','', { RaiseError => 1, AutoCommit => 1 } );
> $dbh->{HandleError} = \&error_handler;
>
> My error handler looks like:
>
> sub error_handler {
> my @err = @_;
>
> print "Error handler triggered!\n";
>
> return 0;
> }
>
> I have tried:
> - $dbh->do ( $restore_command )
> - $sth = $dbh->prepare( $restore_command ); $sth->execute(); …
>
> I've tried with and without $dbh->{odbc_exec_direct} = 1 and also not specifying it.
>
> The MDAC version on the machine is recent: version 2.82.3959.0.
>
> The version of DBI is 1.604.
>
> I have tried running a DBI trace at up to level 15, and there doesn't seem to be anything of interest.
>
>
>
> Has this been brought up before? Has someone encountered it?
>
> If there are other things I should try, I would very much appreciate the suggestions!
>
> I'm completely at a loss where the problem is. Code? DBD? DBI? SQL Server? mdac?
>
> Thanks
> -rt
>
>
>
>
>
Can I see the rest of the code after the prepare please?
Preferably a small self contained and complete example would be best.
Are you calling odbc_more_results after execute until it returns false?
Martin
–
Martin J. Evans
Easysoft Limited
http://www.easysoft.com
Thread Previous
|
Thread Next
-
Error during SQL Server restore fails to propagate back to DBI client on Windows
by pr -
Re: Error during SQL Server restore fails to propagate back to DBI client on Windows
by pr
Re: Error during SQL Server restore fails to propagate back to DBIclient on Windows
by Martin Evans-
Re: Error during SQL Server restore fails to propagate back to DBI client on Windows
by pr -
Re: Error during SQL Server restore fails to propagate back to DBIclient on Windows
by Martin Evans -
Re: Error during SQL Server restore fails to propagate back to DBI client on Windows
by pr -
Re: Error during SQL Server restore fails to propagate back to DBIclient on Windows
by Martin J. Evans
beneficial user method case fix win7 freezing user includes your choice for you to return back the adjustments before the particular scan. Lastly, the actual pc registry resources usually are extremely inexpensive as in comparison to specialized expenses and is usually performed by any person at home. The particular usability, performance advancements and value for cash should have restore device for pc maintenance at each and every household. Attempt it out these days and you can certainly not rue this!






