Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Update conflict
Message
From
18/11/2010 10:17:46
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01489567
Message ID:
01489587
Views:
50
The truth is that I was too busy and had my mind on other pressing matters, to really dig into the program.

>Why go half way?
>
>Select NVL(max(itemnum), 0) from inspdata where jobnum==lnJobnum into array lnMaxItem
>RETURN lnMaxItem[1]
>
>
>Also if table/view is buffered it'll require
>
>
>WITH (BUFFERING = .T.)
>
>
>
>>It may not be related, but instead of Calculate, I would use a SQL Select statement instead, since it doesn't move the record pointer.
>>
>>IF !EOF('inspdata') AND !BOF('inspdata')
>>   local lnjobnum
>>   lnJobnum=inspheader.jobnum
>>   Select max(itemnum) from inspdata where jobnum==lnJobnum into array lnMaxItem
>>   RETURN lnMaxItem
>>ELSE
>>   Return 0
>>endif
>>
Previous
Reply
Map
View

Click here to load this message in the networking platform