0

I am running a FoxPro OLEDB query with several joins over a fairly large dataset. However despite only asking for "MAX" or "TOP 100" [rows] data, I get the following error:

System.Data.OleDb.OleDbException (0x80004005): File c:\users\appX\appdata\local\temp\4\00004y7t002o.tmp is too large. [LOCAL]

OR

System.Data.OleDb.OleDbException (0x80004005): Error writing to file c:\users\appX\appdata\local\temp\00002nuh0025.tmp. [REMOTE]

(I have tried the query both locally and remotely).

Seemingly the OLEDB query creates/deletes a huge amount of temp files, e.g.

enter image description here

This would suggest my query is simply too large and will require several smaller queries/workarounds.

The question is: is this a known issue? Is there an official workaround? Would the FoxPro ODBC adapter have the same problem?

PeterX
  • 2,713
  • 3
  • 32
  • 42
  • You should show a simple query. Are you using SELECT TOP(100) PERCENT or TOP(100) ROWS? Notice the difference. – Ross Bush Nov 26 '14 at 02:21
  • Can you post the actual query you are trying to run? You might be able to optimize by running smaller queries into temp cursors and then your final query. – DRapp Nov 26 '14 at 03:03

1 Answers1

2

Basically 2GB is the upper limit for any file that Visual FoxPro has to deal with. None of those temp files are anywhere near that. Does the location they are being created in have enough disk space? Are there user disk quotas in effect?

Alan B
  • 4,086
  • 24
  • 33
  • No quotas and disk space is available, but this was just while I was looking at the files in the directory - it's quite possible a temp file exceeded the 2GB file limit. I've now used a series of more specific queries to avoid the huge data-set. (I knew about FoxPro 2GB file limit, but not as part of an OLEDB query). – PeterX Nov 27 '14 at 01:07
  • 1
    Doesn't matter - the OLEDB driver is still using the same VFP DLLs so you have that ceiling regardless. – Alan B Nov 27 '14 at 08:25