in reply to Re: Perl OLE DB foxpro
in thread Perl OLE DB foxpro

Use cursor type like this

$q="SELECT order_bill_n, srok_date FROM orders WHERE ALLTRIM(UPPER(ord +er_bill_n)) LIKE '%22134%' order by order_bill_n desc "; $sthfox=$dbhfox->prepare($q, { ado_cursortype => 'adOpenForwardOnl +y' }) or die "Can't prepare statement: $DBI::errstr"; $sthfox->execute() or die "Can't execute statement: $DBI::errstr";

Error changed:

OLE exception from "Microsoft OLE DB Provider for Visual FoxPro":\r [error] \r [error] Unable to create temporary work files.\r [error] \r Win32::OLE(0.1704) error 0x80004005: "Unspecified error"\r in METHOD/PROPERTYGET "Open" at D:/usr/local/bin/perl/site/lib/DBD/ADO +.pm line 1136\r DBD::ADO::st execute failed: Can't Open Recordset for 'SELECT order_bi +ll_n, srok_date FROM orders WHERE ALLTRIM(UPPER(order_bill_n)) LIKE ' +%22134%' order by order_bill_n desc '\r

Replies are listed 'Best First'.
Re^3: Perl OLE DB foxpro
by marto (Cardinal) on Apr 12, 2011 at 08:02 UTC
    [error] Unable to create temporary work files.

    It looks as though you don't have write access to where the driver is trying to write these temp files. This could be TMP or TEMP on Windows, or somewhere else depending how foxpro works (I've no idea, I've never used it). I'd check the eventlog to see if there is anything related to this, or see if one of the sysinternals tools may be able to help you find out what's going on. Perhaps reading some of the google search results will provide an answer.