Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

APPEND FROM delimited file 2

Status
Not open for further replies.

EncinoMan

Programmer
Jun 23, 2006
6
0
0
US
At the dot-prompt of dBase 3plus, I am trying to append from a txt file containing fields delimited by '|'. The command> append from <txt filename> type sdf delimited with '|' does not work. It appends but leaves the pipes in the data. Leaving the "type sdf" out gives same results. My empty dbf is defined with fields that match the delimited txtfile data. I know I've done this before with comma-delimited files, etc, but... I'd appreciate any suggestions. Thanks!
 
Hello,

I *think* you have to use either a literal or a character string in parenthesis:

Code:
append from myfile.txt delimited with character |

Should probably work

Regards

Griff
Keep [Smile]ing
 
Thanks very much, Griff and Jock. I'm still fighting my problem. My source file is in Excel 2003 format. I did a save-as, creating files in different formats (CSV, text, text tab-delimited, DBF) then tried append-from, trying both the dBase3 dot-prompt and a small Clipper program. No luck yet. I tried the function, Jock, but it uses some functions that aren't known to my Clipper S87 version. What bugs me is that a few days ago, I was able to take another Excel file and append it into a DBF but I aobviously can't remember the steps I used to to it. Argh!
 
Hi, Encinoman

Well, if the source is Excel, wgat to do is file/save as and choose type CSV (comma delimited). That is compatible with the simple "append from filename delimited" command in clipper S'87 version.

The biggest problem is if the Excel sheet has multi-line text cells, because those will have embedded CR's, which will mess up the import, but if you format the column in Excel to eliminate that first it should work.

However any currency fields will have $'s & will have to be imported into text fields and converted later and any dates will come in as YYYYMMDD (dtos format).

Jock
 
Jock,

You should get a royalty on this issue, over & over again.

Jim C.
 
Jock, Griff, it worked! Thanks very much!
Bill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top