Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Append not Appending
Message
De
26/05/1998 16:43:49
 
 
À
26/05/1998 16:39:05
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00102110
Message ID:
00102112
Vues:
27
>Here is a code segment that I am using to produce a claim number for a child table. It does a lookup in a table to see if any claims have already been entered for the current account. If so, it increments the last used claim number and returns the new claim number. If a claim has not been entered for the current account, it will add a record to the claimnumbers table and set the claim number to 1 for the current account.
>
>This routine works fine with local data. However, when running with shared data on a file server, the append blank is not appending. Can anybody tell me why?
>
>nArea = select()
>select claimnumbers
>
>if seek(account.a_id, 'CLAIMNUMBERS', 'PRIMARY')
>
> if DJ_RecLock()
> nClaimNo = claimno + 1
> replace claimno with nClaimNo
> unlock
> else
> nClaimNo = -1
> endif
>
>else
> append blank
>
> nClaimNo = 1
> replace a_id with account.a_id, claimno with nClaimNo
>endif
>
>select (nArea)
>
>return nClaimNo
>
>Thanks
>Dan Jurden
>dan_jurden@ciccorp.com

Try to issue
select claimnumbers
right before APPEND BLANK, or even better use
INSERT into claimnumbers Values(..)
Edward Pikman
Independent Consultant
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform