Giter VIP home page Giter VIP logo

dbf's People

Contributors

alexelin avatar fertkir avatar jamel avatar mehanika avatar sferra avatar valery1707 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dbf's Issues

Unsupported Dbf field type

Hey,
I have used this library
i m getting this error
Caused by: org.jamel.dbf.exception.DbfException: Unsupported Dbf field type: 20
Can you help me to resolve this error?

Thanks

Typo on README

The README.md section 'Build from sources' you mentioned

...
./grablew clean build

when it should be

...
./gradlew clean build

Memo field

Return null when i tried to read memo field, is not supported? How can i read it?

Write to dbf files

Hi,

the read API looks really great ๐Ÿ‘ and I would love to use it, but I also need a write API.

Any plans to implement such a functionality?
I would do it myself, if I won't be on a tight schedule

Thanks anyways,
Chris

Reading null Date

There are empty values in Date column in file I am trying to parse, your (in other cases very helpful library) is parsing them as some "extreme Date value" with year 17793. Is it possible to update library to parse them as null, which, I think, is expected meaning? File I am parsing can be downloaded from https://liehweb.financnasprava.sk/data/export/cisOLDDBF.zip in this zip it is Subjekt2.dbf file. This code snipet should reproduce it (first expected null value is in first record).

File file = new File("src/test/resources/Subjekt2.dbf");
        try (DbfReader reader = new DbfReader(file)) {

            Object[] row;
            while ((row = reader.nextRecord()) != null) {
                Date expectedNullDate = ((Date) row[11]); // <- extreme date parsed here
                if(17000 < expectedNullDate.getYear()){ //workaround
                    expectedNullDate = null;
                }
            }
        }

Don't hurry, my workaround is OK for some time ;-)

Error while reading a record marked to be deleted

Hi,

When I'm reading a dbf with a record marked to be deleted it raises and error.

DbfReader reader = new DbfReader(new File("path_to_some_dbf_file"));
Object[] row;
int count = 1;
while ((row = reader.nextRecord()) != null) {
}

The error appears in reader.nextRecord() ( the line 58 of my class )

Caused by: org.jamel.dbf.exception.DbfException: Failed to parse Number from SHB06
at org.jamel.dbf.DbfReader.readNumericValue(DbfReader.java:137)
at org.jamel.dbf.DbfReader.readFieldValue(DbfReader.java:100)
at org.jamel.dbf.DbfReader.nextRecord(DbfReader.java:81)
at com.openkm.plugin.form.values.OptionSelectProveedoresList.getOptions(OptionSelectProveedoresList.java:58)
... 65 more
Caused by: java.lang.NumberFormatException: For input string: "F 0"
at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1250)
at java.lang.Double.valueOf(Double.java:504)
at org.jamel.dbf.DbfReader.readNumericValue(DbfReader.java:135)
... 68 more

Getting fields by column names

Hi,

Would be good to have ResultSet-like API for DbfReader with ability to get fields by column names, e.g.

DbfRow row;
while ((row = reader.nextDbfRow()) != null) {
    totalSum += row.getDouble("BalanceUSD");
}

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.