I'm assuming your timest[0] is a string, if it's not, you'll need to convert it to a string that corresponds to the same format as the to_timestamp call
conn.select("SELECT * FROM EURUSD where timest = ( select max( timest ) from EURUSD ) and rownum = 1 union all " + "SELECT * FROM EURCHF where timest = ( select max( timest ) from EURCHF ) and rownum = 1 union all " + "SELECT * FROM EURGBP where timest = ( select max( timest ) from EURGBP ) and rownum = 1 union all " + "SELECT * FROM USDCHF where timest = ( select max( timest ) from USDCHF ) and rownum = 1 union all " + "SELECT * FROM GBPUSD where timest = ( select max( timest ) from GBPUSD ) and rownum = 1 union all " + "SELECT * FROM GBPCHF where timest = ( select max( timest ) from GBPCHF ) and rownum = 1 union all " + "SELECT * FROM EURJPY where timest = ( select max( timest ) from EURJPY ) and rownum = 1 union all " + "SELECT * FROM USDJPY where timest = ( select max( timest ) from USDJPY ) and rownum = 1 union all " + "SELECT * FROM GBPJPY where timest = ( select max( timest ) from GBPJPY ) and rownum = 1 union all " + "SELECT * FROM CHFJPY where timest = ( select max( timest ) from CHFJPY ) and rownum = 1"); while (rs.next()) { if (rs.getString("SYMBOL").equals("EUR/USD")) { symbol[0] = rs.getString("SYMBOL"); timest[0] = rs.getTimestamp("TIMEST"); openBid[0] = rs.getDouble("BIDPX"); openAsk[0] = rs.getDouble("ASKPX"); } else if (rs.getString("SYMBOL").equals("EUR/CHF")) { symbol[1] = rs.getString("SYMBOL"); timest[1] = rs.getTimestamp("TIMEST"); openBid[1] = rs.getDouble("BIDPX"); openAsk[1] = rs.getDouble("ASKPX");................................................ symbol[9] = rs.getString("SYMBOL"); timest[9] = rs.getTimestamp("TIMEST"); openBid[9] = rs.getDouble("BIDPX"); openAsk[9] = rs.getDouble("ASKPX"); equals(rs);
Not quite understand - do you have all this data in numerous tables and you want to select the latest transactions from each table - is it true?
In any case, I don't think your java part is not quite OK, as you should not have rs.getString("symbol") more than once within the rs.next() loop.
You first assign String s = rs.geString("symbol") and then use this string for conditions.
The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.
One of a set of tools we're offering as a way of saying thank you for being a part of the community.
I remember the day when someone asked me to create a user for an application developement. The user should be able to create views and materialized views and, so, I used the following syntax:
(CODE)
This way, I guessed, I would ensure that use…
This video shows how to Export data from an Oracle database using the Datapump Export Utility. The corresponding Datapump Import utility is also discussed and demonstrated.