_secMaster.setClock(Clock.fixed(now, ZoneOffset.UTC));
_version1Instant = now.minusSeconds(100);
_version2Instant = now.minusSeconds(50);
s_logger.debug("test data now: {}", _version1Instant);
s_logger.debug("test data later: {}", _version2Instant);
final SimpleJdbcTemplate template = _secMaster.getDbConnector().getJdbcTemplate();
template.update("INSERT INTO sec_security VALUES (?,?,?,?,?, ?,?,?,?)",
101, 101, toSqlTimestamp(_version1Instant), MAX_SQL_TIMESTAMP, toSqlTimestamp(_version1Instant), MAX_SQL_TIMESTAMP, "TestSecurity101", "EQUITY", "D");
template.update("INSERT INTO sec_security VALUES (?,?,?,?,?, ?,?,?,?)",
102, 102, toSqlTimestamp(_version1Instant), MAX_SQL_TIMESTAMP, toSqlTimestamp(_version1Instant), MAX_SQL_TIMESTAMP, "TestSecurity102", "EQUITY", "D");
template.update("INSERT INTO sec_security VALUES (?,?,?,?,?, ?,?,?,?)",
201, 201, toSqlTimestamp(_version1Instant), toSqlTimestamp(_version2Instant), toSqlTimestamp(_version1Instant), MAX_SQL_TIMESTAMP, "TestSecurity201", "EQUITY", "D");
template.update("INSERT INTO sec_security VALUES (?,?,?,?,?, ?,?,?,?)",
202, 201, toSqlTimestamp(_version2Instant), MAX_SQL_TIMESTAMP, toSqlTimestamp(_version2Instant), MAX_SQL_TIMESTAMP, "TestSecurity202", "EQUITY", "D");
_totalSecurities = 3;
// id bigint not null,
// key_scheme varchar(255) not null,
// key_value varchar(255) not null,
template.update("INSERT INTO sec_idkey VALUES (?,?,?)",
1, "A", "B");
template.update("INSERT INTO sec_idkey VALUES (?,?,?)",
2, "C", "D");
template.update("INSERT INTO sec_idkey VALUES (?,?,?)",
3, "E", "F");
template.update("INSERT INTO sec_idkey VALUES (?,?,?)",
4, "GH", "HI");
// security_id bigint not null,
// idkey_id bigint not null,
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
101, 1);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
101, 2);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
101, 3);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
102, 1);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
102, 2);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
102, 4);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
201, 2);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
201, 3);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
202, 2);
template.update("INSERT INTO sec_security2idkey VALUES (?,?)",
202, 3);
}