Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Data Refresh Header-Good, Items-Bad
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
00984056
Message ID:
00984163
Vues:
37
It's necessary to call this from a SQL-select because the computer inserting the records is not necessarily the computer running the SQL-Select statement. This application typically involves multiple computers.

Here's the thing that baffles me:
One computer inserting records will issue (simplified version)
insert into sohead (sonum) values (lnSONum)
insert into soitems (itemnum) values (lnItemNum)
flush

Then another computer will run the SQL-Select query and it will immediately see the new records in the sohead table but won't see the new records in the soitems table.

Another thing occurred to me that might be a little different. The UDF that the SQL-Select statement calls uses the soitems table again like such

lparameters lnSONum
local lnSelect,lcItemList
lnSelect=select()
lcItemList=''
use soitems in 0 shared alias soitems_again
sele soitems_again
locate for sonum=lnSONum
do while found()
lcItemList=lcItemList+iif(!empty(lcItemList),',','')+alltrim(str(soitems.itemnum))
continue
enddo
use in soitems_again
select (lnSelect)
return lcItemList

Any idea if using the table again can cause Foxpro to only look in the cache rather than looking on the drive?
Brandon Harker
Sebae Data Solutions
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform