/** * ADVANCED: * Set the receiver's read SQL string. * This allows the user to override the SQL generated by EclipseLink, with their own SQL or procedure call. * The arguments are translated from the fields of the read arguments row, * through replacing the field names marked by '#' with the values for those fields. * Note that this is only used on readAllObjects(Class), and not when an expression is provided. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * <p> * Example, "select * from EMPLOYEE" */ public void setReadAllSQLString(String sqlString) { if (sqlString == null) { return; } ReadAllQuery query = new ReadAllQuery(); query.setSQLString(sqlString); setReadAllQuery(query); }
/** * ADVANCED: * Set the receiver's read SQL string. * This allows the user to override the SQL generated by EclipseLink, with their own SQL or procedure call. * The arguments are translated from the fields of the read arguments row, * through replacing the field names marked by '#' with the values for those fields. * Note that this is only used on readAllObjects(Class), and not when an expression is provided. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * <p> * Example, "select * from EMPLOYEE" */ public void setReadAllSQLString(String sqlString) { if (sqlString == null) { return; } ReadAllQuery query = new ReadAllQuery(); query.setSQLString(sqlString); setReadAllQuery(query); }
/** * ADVANCED: * Set the receiver's read SQL string. * This allows the user to override the SQL generated by EclipseLink, with their own SQL or procedure call. * The arguments are translated from the fields of the read arguments row, * through replacing the field names marked by '#' with the values for those fields. * Note that this is only used on readAllObjects(Class), and not when an expression is provided. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * <p> * Example, "select * from EMPLOYEE" */ public void setReadAllSQLString(String sqlString) { if (sqlString == null) { return; } ReadAllQuery query = new ReadAllQuery(); query.setSQLString(sqlString); setReadAllQuery(query); }
/** * PUBLIC: * Read all of the instances of the class from the database return through execution the SQL string. * The SQL string must be a valid SQL select statement or selecting stored procedure call. * This operation can be customized through using a ReadAllQuery. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * * @see ReadAllQuery */ public Vector readAllObjects(Class domainClass, String sqlString) throws DatabaseException { ReadAllQuery query = new ReadAllQuery(); query.setReferenceClass(domainClass); query.setSQLString(sqlString); query.setIsExecutionClone(true); return (Vector)executeQuery(query); }
/** * PUBLIC: * Read all of the instances of the class from the database return through execution the SQL string. * The SQL string must be a valid SQL select statement or selecting stored procedure call. * This operation can be customized through using a ReadAllQuery. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * * @see ReadAllQuery */ public Vector readAllObjects(Class domainClass, String sqlString) throws DatabaseException { ReadAllQuery query = new ReadAllQuery(); query.setReferenceClass(domainClass); query.setSQLString(sqlString); query.setIsExecutionClone(true); return (Vector)executeQuery(query); }
/** * PUBLIC: * Read all of the instances of the class from the database return through execution the SQL string. * The SQL string must be a valid SQL select statement or selecting stored procedure call. * This operation can be customized through using a ReadAllQuery. * Warning: Allowing an unverified SQL string to be passed into this * method makes your application vulnerable to SQL injection attacks. * * @see ReadAllQuery */ public Vector readAllObjects(Class domainClass, String sqlString) throws DatabaseException { ReadAllQuery query = new ReadAllQuery(); query.setReferenceClass(domainClass); query.setSQLString(sqlString); query.setIsExecutionClone(true); return (Vector)executeQuery(query); }