Questions tagged as 'jpa'

3
answers

Multiple query values with JPA / Sprint and Rest

Good morning, I need to make a query via REST where multiple IDs will be sent for example (ID: 1, ID: 2, ID: 3, etc). To search only for an ID I use findById(codigo) , but I do not know how to use multiple data. As I'm using RESTFull, how...
asked by 28.09.2018 / 15:20
0
answers

localhost has redirected you too many times

Good afternoon, I'm trying to direct a system user to an error page if something goes wrong with the session or if the user has denied access to a particular page etc ... I'm using Spring Security for this. in my applicationContext.xml cla...
asked by 08.11.2018 / 22:44
1
answer

Jpa with hibernate implementation does not generate tables in postgresql

Good night to all I'm using Jpa with hibernate implementation for among other features generate tables, the problem is that from one time to another the tables stopped being generated, someone else has gone through this Follow my persistence....
asked by 15.07.2014 / 02:08
2
answers

deleting an object from the database with jpa 2 and jsf 2

Well I'm trying to make an exclusion using jpa with jsf but I'm not having success. I have my table. <p:dataTable value="#{mbProduto.produtos}" var="produtos" paginator="true" rows="10" pagina...
asked by 17.07.2014 / 03:22
0
answers

Difficulty with JPA annotations for entity relationships

I have the following relationships: CategoriaPeca , SubcategoriaPeca and Peca . A CategoryPart can have several SubcategoryPart , and a SubcategoryPart can have several CategoryPart , a part can only be in one SubcategoryPeca and onl...
asked by 06.09.2018 / 14:37
0
answers

Dynamically connect to an Oracle database for each JAX-RS request

I am developing a project in JBoss Seam to provide some services via JAX-RS in Wildfly 9. The DBMS used is Oracle 10g, and the services that will be available are form features that the company develops in Oracle Forms. The procedures, fun...
asked by 23.07.2018 / 14:15
0
answers

JPA - CascadeType.REMOVE after entity is deleted by orphanRemoval = true

public class PrimeiroNivel { @OneToMany(mappedBy="primeiroNivel", orphanRemoval=true) private List<SegundoNivel> niveisSecundarios; } public class SegundoNivel { @JoinColumn(name="primeirNivel") @ManyToOne pri...
asked by 24.07.2018 / 20:10
1
answer

DTO with List using JpaCriteria

I have two entities OperatorDate and HourDate . These two entities have other relationships that when I search with rest, it comes very unnecessary. To avoid this, I have created two DTO tables, DotOperator and DoodOper , in order to set...
asked by 16.10.2018 / 14:42
0
answers

One of the tables is not being created - JPA / Hibernate with MySQL

I have a problem running my test class: import javax.persistence.EntityManager; import br.com.teste.jpa.c_mapeamento.model.Conta; public class PopulaConta { public static void main(String[] args) { EntityManager manager = JPAUt...
asked by 30.08.2018 / 22:50
0
answers

How to change the @GeneratedValue used by Spring through Spring's AbstractPersistable class?

I'd like to use @GeneratedValue(strategy = GenerationType.SEQUENCE, ... ... when I'm extending the class AbstractPersistable , but I do not know if that's possible. From what I saw in the documentation, the class AbstractPersi...
asked by 19.05.2018 / 12:41