Coder Social home page Coder Social logo

Comments (4)

Machado117 avatar Machado117 commented on June 13, 2024 1

I see, it works if instead I encrypt the age field as int64 in acra and use setLong in the code.

from acra.

Machado117 avatar Machado117 commented on June 13, 2024 1

Just confirmed that it works if I use setCharacterStream instead of setString

from acra.

Lagovas avatar Lagovas commented on June 13, 2024

I reproduced error with create table mytable(name bytea, age integer) and such encryptor's config. Java driver sends string as VARCHAR (oid=1043) to store it in the database as TEXT. AcraServer captures db's response with BYTEA type and replace it to TEXT type (oid=25). And it is mismatch with driver expectations.
WIthout Acra database can cast some real types that it uses for storage to the types application sends if it can be casted as 1:1. For example if database stores 64 bit integer and application sends data as 32bit integer then database can return it as 32 bit integer. But cannot do it in opposite way: 32 -> 64.

For now, Acra maps str data type to TEXT type from PostgreSQL. So you should send and deal with results as with TEXT, not VARCHAR types. I didn't find how to do it with java PostgreSQL driver quickly, because I'm not java developer. I will try to find it one more time in driver's docs more deeply, but a bit later.

from acra.

vixentael avatar vixentael commented on June 13, 2024

that was fast

from acra.

Related Issues (20)

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.