dbase icon indicating copy to clipboard operation
dbase copied to clipboard

No support for FoxPro's .DBF

Open siran opened this issue 8 years ago • 3 comments

When trying to read a FoxPro DBF file, I got: "Format dBASE III PLUS does not support field T"

This is not an issue, it just doesn't support it and I thought you might explicitely say so in documentation to avoid confusion.

siran avatar Jan 15 '17 23:01 siran

Please send me example file.

I would be glad if you write the customization on your own and then send me pull request

  1. Add new Field in src/fields
  2. Register new field in Field::create and Field::getTypes. Do not forget to add Field::TYPE_ constant
  3. Add FoxitPro DBase II format in src/formats. Do not forget to add new field as supported fields in the format. In Format::createHeader you can check if the field was actually FoxPro format - throw exception if not
  4. Register new format in FormatFactory::initializeFormats. Add new registerFormat call similar to Format::DBASE3

If possible write unit tests for new code

During the time your PR is not yet merged you can use your own fork in your project

  1. Add you fork as repository to your compose.json https://getcomposer.org/doc/05-repositories.md#vcs

  2. Change package version to dev-master ("org.majkel/dbase": "dev-master")

majkel89 avatar Jan 16 '17 09:01 majkel89

Hello, I have the same error-message:

Format dBASE III PLUS does not support field T

But I don't know how to handle this. I had read your instructions but I'm not sure how to do.

Please help.

Thanks and best regards!

aauerswald avatar Sep 29 '18 10:09 aauerswald

https://github.com/luads/php-xbase

Use this one support much more types ! (date/timestamp/integer , ....)

neoteknic avatar Mar 18 '20 14:03 neoteknic