spring-data


Is it possble to write query at JPA entity property level


Is it possble to write query at JPA entity property level?
Basically I want to add a property in an entity which is not an actual column and value should computed with query.
Something like:
#Entity
#Table(schema = "quote", name = "QUOTE_SCENARIO")
public class QuoteScenario {
#Query(Select max(Lead_Time) from differentEntity)
private Integer leadTime;
}
No. This is not possible as the query annotation is at the method level. You can try and do this using formula in Hibernate.

Related Links

#EnableJpaRepositories.enableDefaultTransactions = false not working
Spring Data JPA - Update Whole object
spring data load children and query by child property
What is the difference between all these spring DAO templates
Spring Batch and Neo4j: Transaction synchronization is not active
spring data not get id annotaion on method
spring jpa query dsl doesnt work with projection
Spring Elasticsearch data repository in Weld SE CDI - UnsatisfiedResolutionException
Spring Data query by example and Primefaces datatable filtering
spring-data-parent and spring-data-* projects with java 6?
SpringJPA + Eclipselink: No [ManagedType] was found for the key class. Not using persistance.xml
spring Batch partitioning + spring-data-mongo integration example
Trying to use Crate.io NoSql database with an existing Spring Data / Mysql project
How spring data generate sql according to method name?
Spring Data Jpa equality of two column
Spring Data Mongodb findBy In case insensitive

Categories

HOME
jboss
apple-push-notifications
swi-prolog
windows-10
haproxy
hid
nsview
iptables
navigation
clone
reportviewer
azure-graph-api
twitter-oauth
feature-extraction
stimulsoft
amazon-elb
squid
sonicwall
scala-ide
cloudsim
mod-wsgi
jpa-2.1
boolean-logic
microprocessors
basic-authentication
tightvnc
progid
wampsharp
epplus
char-pointer
testlink
runtimeexception
love2d
jade4j
cartopy
ng-repeat
utf
jacoco-maven-plugin
grails3.2.0
zend-form
daz3d
spring.net
android-mediarecorder
algebra
nslayoutconstraint
test-data
polymaps
instafeedjs
gawk
libharu
nunit-console
dpkg
fragmentstatepageradapter
meld
mnesia
bayesglm
apache-commons-digester
ora-04091
extend
alwayson
webproject
deque
subfolder
mxe
jcheckbox
google-hangouts
dc
visual-studio-6
nachos
redpitaya
jomsocial
progress-db
insertonsubmit
microformats
sly-scroller
rikulo
mongo-jackson-mapper
arel
jquery-cycle
email-verification
user-forums
idispatch
getproperty
zotonic
type-safety
glx
delphi-prism
outlook-2007-addin
icicles
tabbarcontroller
ixmldomdocument
iphone-sdk-4.3
google-translator-toolkit
index.dat
efs
isapi-redirect

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App