Giter Club home page Giter Club logo

Comments (10)

majkel89 avatar majkel89 commented on August 17, 2024 1

Hi,
Your contribution is welcome.

I think better documentation of DBase Level IV format is in http://www.oocities.org/geoff_wass/dBASE/GaryWhite/dBASE/FAQ/qformt.htm#B (see DEVELOP.md)

According to this documentation only C, D, F, L, M, N are supported. C, D, L, M, N are already present so you will have to implement F field.

F is not supported by DBase Level III so you will have to implement new format DBase4.

Add the new format to FormatFactory.

Currently DBase3 format does not check the version in header. I think you will have to add the version check to Format::readHeader.

I would be glad to receive sample of DBase Level IV file with float field so that I will be able to help you further.

from dbase.

stokescomp avatar stokescomp commented on August 17, 2024 1

I am adding the files that should make dBase IV and Float a new field.
One question I have is from the Builder class. Should it defualt to DBASE3?
private $formatType = Format::DBASE3;

I made a new FloatField in field folder and I used this for the length and decimal count:
`class FloatField extends Field {

/**
 * FloatField constructor.
 */
public function __construct() {
    $this->length = 16;
    $this->decimalCount = 14;
}`

This page says width 16:
https://www.stattransfer.com/support/manual/dBase.html

I found a nice page that shows what the version numbers are for each type.
https://www.loc.gov/preservation/digital/formats/fdd/fdd000325.shtml
0x03 FoxBASE+/Dbase III plus, no memo
0x30 Visual FoxPro
0x83 FoxBASE+/dBASE III PLUS, with memo

It looks like I have a dbase III file that has Floats. So I will add Float as a type for dbase III. In addition to adding dbase4.
According the file header of the file it is version 03. But when I open it with DBF Manager it thinks it is a Visual Foxpro file. How can the code tell the difference between Visual Foxpro and dBase III?
I have attached the file to this message.
TestVisualFoxproDBF.zip

image

from dbase.

stokescomp avatar stokescomp commented on August 17, 2024 1

I got busy and didn't fix this. I did enough to support what I needed though.

from dbase.

majkel89 avatar majkel89 commented on August 17, 2024

Hard to tell if the remains of specifications are wrong or your file corrupted.
For me it would be ok to just add the float field to dBase III.

Try to test the lib with files in https://www.clicketyclick.dk/databases/xbase/index.shtml.en

from dbase.

mzvarik avatar mzvarik commented on August 17, 2024

Did you fix this?
I have the same issue... and cannot open the DBF using this library.. it was generated using Visual FoxPro

from dbase.

mzvarik avatar mzvarik commented on August 17, 2024

Oh, okay... created the "FloatField.php" from "NumericField.php" and it opens the file now. Thanks.

from dbase.

mzvarik avatar mzvarik commented on August 17, 2024

Another solution is to edit the exiting DBF file and change the header structure of that column from Float to Numeric (it also can have decimals)

from dbase.

neoteknic avatar neoteknic commented on August 17, 2024

tried to make a fork but no time for it.
And I discovered antoher package :
https://github.com/luads/php-xbase

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

from dbase.

razvanphp avatar razvanphp commented on August 17, 2024

Maybe related:

org\majkel\dbase\Exception
Format `dBASE III PLUS` does not support field `I`

from dbase.

MohammedRawhi avatar MohammedRawhi commented on August 17, 2024

Hi, I need help,
I have table built by dbase iii+ , and it was created with password, and I forgot the password, how can I reset on change the password.

from dbase.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.