0

My system still keeps an attribute of which i had edited the name.

I have an entity bean in which i had updated the name of the attribute, of type boolean. I had changed its name from "considered" to "usable". I changed also the name in all involved queries.

If i try to use an INSERT query (in which i previously had the attribute "considered", now having "usable" - with the proper boolean value set), using, so, the attribute "usable", the system raises the exception of missing default value for "considered":

"org.hibernate.engine.jdbc.spi.SqlExceptionHelper: Field 'considered' doesn't have a default value"

(it tells me "hey, you have not assigned a value to "considered"").

I have tried to perform the deployment of my app with the value of HBM2DDL.AUTO (the property in the persistence.xml file) set to "create-drop" (I got that with this value, when deploying the application the system deletes the data and the schema and then create it again - PLEASE, TELL ME IF I GOT IT WRONG). I had started with value="update" and kept working with this setting. Finally, the attribute "considered" does not get removed (i expect it to get removed - i am no longer using it!).

So, i cannot perform INSERT queries because of an attribute that i tried to remove - replacing it with another one - that i don't use anymore, but that is still "alive" in the system.

I hope i have described well my issue.

Could anyone help me? Thanks.

tcoddis
  • 21
  • 5
  • 2
    Welcome to Where Developers Learn, Share, & Build Careers! Please be a bit more specific when asking a question: *What have you tried so far with a code example?* ([I downvoted because there is no code](http://idownvotedbecau.se/nocode/)) / *What do you expect?* / *What error do you get?* **For Help take a look at "[How to ask](//stackoverflow.com/help/how-to-ask)"** – Hille Feb 15 '19 at 11:29

1 Answers1

0

Finally I found out that there was some conflict. I had previously created a Eclipse project as a try, where putting some of the same code of my app above. So, due to Maven links and dependencies (I am new Maven, for this reason I took many days to find the problem out) set by my colleague, when I deployed my app this "clone" code in the try project got deployed too. I decided to remove the try project and had to remove some .war/.ear files of the try project that got created in my WildFly standalone folder during the deployment.

tcoddis
  • 21
  • 5