Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Invalid Seek Offset - reproducible
Message
From
22/07/2006 04:03:39
 
 
To
21/07/2006 16:45:14
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01137918
Message ID:
01138790
Views:
12
>>(1) limit the cache
>
>=sys(3050,1, 64 * 1024 * 1024)
>=sys(3050,2, 16 * 1024 * 1024)
>
>
>While that usually is a good idea on pure xBase, SQL suffers [more] if starved for memory. I'ld set the backgroud process to at least 64 * 2**10 as well - that doesn't hurt on current machines and keeps vfp chugging even in background. I find on a decent machine 96 to 128 * 2**10 gives better all around handling - YMMV...
>>
>
>>(3) go top, then seek
>
>I often read code going top before scan, locate or seek(). Until now I have not found any issue deleting these [IMHO unneccessary] statements (after making sure no scope "REST" is defined which would lead to a different working pattern if "go top" was eliminated <bg>). Did you find a REPRODUCIBLE scenario where this practice helped ?
>

Thomas,

Last week I came across a situation where I HAD to put a go top

Without the GO TOP, the seek() returns TRUE, but the record pointer is not on the record >> last ASSERT

I couldn't think of any reason
for i = 1 to m.nToDo
			
	SeekKey = eval(ToDo[m.i])
	
	if( empty(m.SeekKey) )
		loop
	endif
		
	IsOutputLine = TRUE
	
	go top in TaxDriverOutput && this is the line I need
	
	do case
	case !m.Success
		exit

	case !seek(m.SeekKey, 'TaxDriverOutput', 'Id')
		assert FALSE
		Success = FALSE
			
	case TaxDriverOutput.td_code <> m.SeekKey && this one fails without the GO TOP
		assert FALSE
		Success = FALSE
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform