Use eclipselink.history.as-of.scn
to configure the query to query the state of the object as-of a database SCN (System Change Number).
Table 4-11 describes this query hint's values.
Note:
This query hint requires Oracle Flashback support.
Example 4-23 Using history.as-of.scn in a JPA Query
import org.eclipse.persistence.config.HintValues; import org.eclipse.persistence.config.QueryHints; query.setHint("eclipselink.AS_OF_SCN", "3");
Example 4-24 Using history.as-of.scn in @QueryHint Annotation
import org.eclipse.persistence.config.HintValues; import org.eclipse.persistence.config.QueryHints; @QueryHint(name=QueryHints.AS_OF_SCN, value="3");
For more information, see:
"Using Oracle Flashback Technology" in Oracle Database Advanced Application Developer's Guide