Importing Ascii File 
Author Message
 Importing Ascii File

Help is needed, I want to read an ascii file and import data from it to a TPS
this ascii file has values separated by commas like

a,1,xyz,3
b,2,abc,5
c,3,qwe,4

it is a plain txt file

is there a template for it?

Help would be appreciated !!!

Diego Sanchez



Mon, 27 Jun 2005 00:30:24 GMT  
 Importing Ascii File
Use the BASIC file driver
Create a field for each value separated by the comma.
Use the PROCESS template with the ascii file as the primary table and the
Topspeed file as the secondary table and in the embed for each record use
the code:

TPS:field1 = ASC:field1
TPS:field2 = ASC:field2
TPS:field3 = ASC:field3
(include additional fields here as shown above)
APPEND(TPSfile)

In the embed for After Closing Files put in the code:

BUILD(TPSFile) to build the keys for the records you appended to the file.

--
Ben E. Brady
http://www.y2kbrady.com/diabetes/
Read the article... don't wait for the movie...


Quote:
> Help is needed, I want to read an ascii file and import data from it to a
TPS
> this ascii file has values separated by commas like

> a,1,xyz,3
> b,2,abc,5
> c,3,qwe,4

> it is a plain txt file

> is there a template for it?

> Help would be appreciated !!!

> Diego Sanchez



Mon, 27 Jun 2005 01:07:07 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Trouble importing ascii file into .tps database file.

2. importing ascii file

3. Importing ASCII File-HELP

4. Importing from an Ascii File

5. Importing and appending ASCII files...

6. Import ASCII data into a DBV file

7. clipper code to import ASCII to a .dbf file

8. Need converter program to translate ascii to ebcdic in mixes ascii/binary file

9. Import Data With File Import

10. Accessing variables created after import in imported files

11. import ascii to apl ws

12. ASCII Import & Date Formats

 

 
Powered by phpBB® Forum Software