[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Converting Xy to dbf

I'm a bit puzzled about the structure of your existing file. First of
all, the initial numbers have to go. A database will automatically
convert them to record numbers (recno in dBase). Second, do you really
mean that many of your records are blank? Which is what
looks like. If so, get rid of them too. It's hard enough when you have
empty fields within records (what Norman was talking about).

Then are "Title," "Code" not really field names, not part of the field
values? If so, they should be the first set of records in the files
(records means rows or sets of items; individual items are fields); then
any decent spreadsheet or db app will pick up that they're field names.
Likewise, what do
 1=*****,2=*****, 3=*****
mean? if the idea is that the first value for this set is one number, the
second is another, and so on, then you don't need or want the "1=", "2=",
and so on. It looks as if your first set of records should be
and then each subsequent row/record contain a title, a code, and three
values, separated by commas.

The actual importing is fairly easy, but you need to set up your file
correctly (Xy's Ci will be invaluable), and to do that you need to
understand some niceties of database structual conventions. I'll be glad
to help, but I really need more information.

I would suggest doing a trial run with a few records and two different
variations on comma delimited. In one, enclose all text fields (including
numbers that aren't going to have math done to them, such as phone
numbers, ZIP codes, and Social Security numbers) in double quotes, with
the delimiting commas outside the quotes, thus:
"First Title","first Code",
with NO spaces between. Leave numeric fields without the quotes. Then try
importing the same set with just the commas between (no quotes). See
which comes over better.

The importing is best done in two steps: first from a properly formatted
Xy file to a spredsheet, then Save As a .dbf file, which can be read by
most database apps. The spreadsheet lets you see if anything is out of
whack, and one can sometimes patch things if there are just a few