main logo
Subject: Re: Low Level very large file copyI have the reuirement
Author: "Chet Gardiner"
Posted: 2003/11/30 03:36:00
 
View Entire Thread
New Search


Foxpro low level file I/O is ALSO limited by Fox 2gig limit.

I've tried it (with VFP 6.0) and it don't work.


----- Original Message -----
From: "bryan wetton" <bryan at wetton DO.T net>
To: <profoxtech@leafe.com>
Sent: Saturday, November 29, 2003 10:23 PM
Subject: Low Level very large file copyI have the reuirement


> I have the requirement ( don't ask why ) to transfer a 20Gb file via
> low-level code.
>
> I had code that was working for smaller files but this size broke it.
>
> I have so far got
>
> [cMyTableNamea is the very large file name .dbf)
>
> nBytes = 100000 ( or an appropriate size 'bite' to work with )
>
> gnErrFile2 = FCREATE("TEMP_N")
> gnFileHandle = FOPEN(cMyTableNamea)
>
> IF FERROR() != 0
> ? "File open error:", FERROR()
> ELSE
>
> * Seek to end of file to determine the number of bytes in the file
> nSize = FSEEK(gnFileHandle, 0, 2) && Move pointer to EOF
> IF nSize > 0
>
>
> *!* DO WHILE !FEOF() < conceptual routine that needs correction
>
> cString = FREAD(gnFileHandle, nBytes)
> =FWRITE(gnErrFile2 , cString)
> *!* ENDDO
> FCLOSE(gnFileHandle)
> FCLOSE(gnErrFile2)
>
> ENDIF
>
>
> Thank you in advance
>
> Bryan
>
>
[excessive quoting removed by server]


 
©2003 Chet Gardiner
<-- Prior Message New Search Next Message -->