Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Whether to Use an Array or a Cursor ?
Message
De
15/08/2013 11:22:27
 
 
À
15/08/2013 09:15:05
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01580497
Message ID:
01580546
Vues:
62
Thanks Madam.But ASCAN() Will search for the Exact existence of record. is it possible with ACSN () to search like record, I mean to say that
If the Array Element consist of "F2 B (Usage Charges)387 530 w" than is it possible to search 'Usage Charges' from Array element and Extract 300 from it using ASCAN.

currently I am Scanning the entire array using For ENFOR and using IF 'Usage Charges' $ laArray(I)=.T., like this
FOR I= 1 TO nU1 && nU1 is the Length of Array
>>>IF 'Usage Charges' $ laArray(I)=.T.
>>>lnRowposition =    VAL(GETWORDNUM(laArray(I), GETWORDCOUNT(laArray(I)) - 1)) && The second last word
>>>lnLeftColumnposition = GETWORDNUM(laArray(I), GETWORDCOUNT(laArray(I)) - 2) && The Third last word
>>>lnLeftColumnposition=VAL(STREXTRACT(lnLeftColumnposition,')',''))
>>>EXIT
>>>ENDIF
>>>ENDFOR
Kinldy Guide




>>I am trying to some Extract Data from a Text file and preform some Manipulation on it.
>>
>>For Extraction of Data I have two options, 1st create a cursor using Append from abc.txt SDF and Use The Locate Command to find my Data inside and extract it.
>>
>>2nd Use an Array. Initially I opted the second option. Now, to extract the Data from The array I am Scaning the entire Array from top Until the record is Matched, but since the volume of Data to be extracted from ech file and the number of files are also too Large, its taking huge time for entire processing.
>
>Just want to point out that the fast way to search in an array is with ASCAN().
>
>Tamar
Harsh
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform