Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Importing wide(?) files
Message
De
11/08/1998 17:49:43
Bruce Gilmour
Cal-Mour Consultants
Calgary, Alberta, Canada
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00125780
Message ID:
00125795
Vues:
18
Hi David. My preference would not be to split the file but, for whatever reason, when I output the file from the proprietary system it is built in the record lenght seems to be limited to around 512 characters so I don't get all the data. I am still exploring to see if this is a limitation of the proprietary system or windows .txt files but thought I should look into other solutions as well. Thanks for your reply. It looks like it will work great. I'll let you know what I find out.

>Bruce,
>
>Did you choose to split the file? VFP should be able to import the whole thing at once provided you don't have too many fields. If you have to put the two files back together I'd do something like:
>
>create cursor awide ( struct of first half, using same field names as real table )
>append from TheWideFile type delimited
>create cursor bnarrow ( struct of second half )
>append from TheNarrowFile type delimited
>select awide
>scan
> scatter memvar
> select bnarrow
> scatter memvar
> skip 1 in bnarrow
> select RealTable
> append blank
> gather memvar
> select awide
>endscan
>
>>OK - so my mind is turning to mush. I have a wide file - about 730 characters wide - that I need to import. It will be in ASCII delimited format. I have divided it into two files of about 480 characters and 240 characters. What is the easiest way to get them into a VFP 5 table. I can APPEND FROM for the first one but then how do I get the rest of the fields from the second file into the proper records. I know which fields are where. Suggested approaches please.
>>TIA
***************************
Bruce Gilmour

"Two things are infinite, the Universe and human stupidity. And I am not sure about the Universe."
- Albert Einstein
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform