About CURRENT_DATE

41-50 of 200Refresh
Forum
7

Group by date / time

. Each entity has it's own field that holds java.lang.Date. There is no function like YEAR(), MONTH() or ... stats WHERE YEAR(record_date) = 2009 GROUP BY YEAR(record_date), MONTH(record_date) or maybe something like this: SELECT COUNT(id) FROM stats WHERE YEAR(record_date) = 2009 GROUP BY DATE
Issue
7

Bug when using SIZE in combination with date lower parameter

there seems to be a bug if I use the lower date select: SELECT j.jobId, SIZE(j.tags) FROM ParserJob j WHERE j.dateCreated < :date This returns a SIZE(j.tags) of 0 Tags, but the only existing ParserJob has 1 Tag. If I run the query: SELECT j.jobId, SIZE(j.tags) FROM ParserJob j WHERE j.dateCreated >= :date I
Forum
7

Order in WHERE Clause affects behaviour on DATE/DATETIME columns

; @Temporal(TemporalType.TIMESTAMP) @Column(name = "myDate") Date myDate; } Now ... would get an IllegalArgumentException: Parameter value [%myQuery%] did not match expected type [java.util.Date (n/a)] because I ... of the WHERE clauses obviously makes a difference. The date column seems to be converted to a String
Forum
7

Using date in where clause

-2013" Here I have created Persons object as java.sql.Date attribute.   But in doing so I am getting ... with date in where clause. The query is invalid because you compare a date (the creationDate field) with a string literal ("07-25-2013"). Replace the string with a date literal or a parameter. n126961
Forum
7

In version 2.5.2_05 does not work greatest by Date

In earlier versions this query worked fine. In version 2.5.2_05 does not work .orderBy(cb.desc(cb.greatest(root.get("createDate").as(Date.class)))).distinct(true) Thank you for your help. Please try build 2.5.2_06 that should fix this regression (of casting to Date). galandor
Forum
7

log entry date/time

It would be very useful if each entry in the log file has a date/time stamp. Thanks, Carl   Version 2.2.2 adds date/time stamps to the log. Thank you for your suggestion. FastModel
Manual
7

Database Schema Evolution

of an old schema is loaded into memory it is automatically converted into an instance of the up to date ... int to Date) the fields are not considered as matching and the new field is initialized ... any date type to any date type. From any collection or array type to any collection or array type, as
JDO Doc
6

javax.jdo.Query

option. Returns: the current setting of the flag Since: JDO 2.0 void setCandidates( Extent pcs) Set ... and instances of wrapper classes are valid. Equality and ordering comparisons of Date fields and Date ... if the filter expression returned false for the evaluation of the current set of variable values. Other values
Tutorial
6

Step 2: Entity Class and Persistence Unit

.Serializable; import java.sql.Date; import javax.persistence.Entity; import javax.persistence ... Long id; private String name; private Date signingDate; // Constructors ... ; this.signingDate = new Date(System.currentTimeMillis()); } // String Representation
Tutorial
6

Step 2: Define a JPA Entity Class

code: package guest; import java.io.Serializable; import java.sql.Date; import javax.persistence ... Date signingDate; // Constructors: public Guest() { } public Guest(String name) { this.name = name; this.signingDate = new Date(System.currentTimeMillis