Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Append From difficulties
Message
 
To
27/07/2005 11:05:30
Scott Sherman
Puyallup Tribal Health Authority
Tacoma, Washington, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01036240
Message ID:
01036251
Views:
14
Scott, I didn't see any problems (I don't have a VFP6 to test with it, but with VFP8 it works)
STRTOFILE([SS]+CHR(9)+[Lori N]+CHR(9)+["12 13th Pl, #236"]+CHR(9)+[Redmond WA]+CHR(9)+[98052]+CHR(9)+[SoSi],"d:\test.txt")
CREATE CURSOR cTest (Fld1 C(50),Fld2 C(50),Fld3 C(50),Fld4 C(50),Fld5 C(50),Fld6 C(50),Fld7 C(50),Fld8 C(50),Fld9 C(50))
APPEND FROM d:\test.txt TYPE DELIMITED WITH " WITH CHARACTER TAB
BROWSE NORMAL
>I am trying to append data from a tab delimited file where some of the fields are empty and there happens to be some commas in a few of the fields. I can use the import wizard and it works fine. It appears that the append function is having a problem with consecutive tabs follows by a string in double quotes that has a comma in the string. The result is the field is moved to the left one field and everything of off after that. I have included a sample line of data with the problem. I am appending into a nine field table with all character fields. I have also included the line of code that I am using and an small display of what should happen and what is happening.
>
>SS Lori N "12 13th Pl, #236" Redmond WA 98052 SoSi
>
>
>APPEND FROM (textFileName) TYPE DELIMITED WITH " WITH CHARACTER TAB
>
>field should actual
>1 SS SS
>2
>3 Lori N Lori N
>4 12 13th Pl, #236
>5 12 13th Pl, #236 Redmond
>6 Redmond WA
>7 WA 98052
>8 98052 SoSi
>9 SoSi
>
>Please and thank you,
>
>Scott Sherman
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform