Questions tagged as 'hibernate'

1
answer

ERROR: column "type" of relation "tb_people" does not exist

Hello. I'm trying to persist a record, but when I run it, it is returning the error below: // ... @Inheritance(strategy = InheritanceType.JOINED) @DiscriminatorColumn(name = "tipo", discriminatorType = DiscriminatorType.STRING) @Discriminat...
asked by 21.01.2017 / 14:55
1
answer

Best Scenarios: Recording in table from n to n Hibernate

I have some doubts about writing records in tables from N to M. My scenario is as follows: InmybankwheninsertingadoctorIinsertinthe"Doctor" table the registration of Doctor, and in "Doctor x Specialty" the specialties of this doctor. Registr...
asked by 26.10.2016 / 15:25
1
answer

Java Test with bank in memory

I'm in doubt when running my application tests: The question is whether Hibernate can be used to create a non-physical database to perform the in-memory tests to make it easier and faster to run the tests in question.     
asked by 02.12.2016 / 11:27
1
answer

Validate date smaller than current date [closed]

My question is as follows. I have a JSP form for registering students with multiple attributes, one of them is the date of birth. Until then I was registering the date only by validating the format (dd / MM / yyyy) and with annotations. But now,...
asked by 17.11.2016 / 14:56
1
answer

How do I search for the ID's in the bank and display the names on the screen?

In my JSF + Primefaces project, I have the following entities: @Entity @Table(name = "geracao") public class Geracao { @Getter @Setter @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; @Getter...
asked by 23.11.2016 / 16:51
0
answers

java.lang.IllegalStateException: Can not create a session after the response has been committed [closed]

Good morning guys, I have a strange problem in my application only after I generate War and send to Integrator, the application does not even open the Login screen, this error is returned: INFO: Exception when handling error trying to reset...
asked by 03.10.2016 / 19:23
1
answer

Query with jpa + hibernate with more than one idt in clause

With hibernate I can do a query by idt as follows: entityManager.find(Empresa.class, idtEmpresa); And this would already return the mapped object of the enterprise class, but what if I wanted to query more than one idt, what would it look l...
asked by 22.10.2016 / 17:49
1
answer

Ticket Generation with Bopepo

I have a system that generates an accounts receivable, and I'm trying to implement the generation of bank boletos, my teacher Advisor has indicated me the tool 'Bopepo' Jrmum. I inserted it into my system and was able to generate a sample ticket...
asked by 16.09.2016 / 20:48
0
answers

Problem with persisting relationship

I have 2 entities, the SubModel that has a list of possible options. I made a unidirectional OneToMany relation, when I do any persistence in the SubModel entity that the list of Options is empty Hibernate does quietly, but without having to inc...
asked by 07.10.2016 / 13:45
0
answers

Arbitrary load of specialized entity in Java / Hibernate, from associations

So, following ... I have the following class structure that Hibernate handles: is a symbol for denoting inheritance, 1 - * is a symbol for denoting an association one for many) [Pessoa] <|- [Medico] [Pessoa] <|- [Professor] [Pes...
asked by 30.08.2016 / 19:20