public static int getAuctionTime( int auctionID ) throws DatabaseException {
		Connection conn = null;
		ResultSet rs = null;
		PreparedStatement ps = null;
		int uid, bids;

		String qGetAuctionTime = "SELECT endingTime FROM auctiontime WHERE auctionID = ?";

		try {
			conn = DBPool.getInstance().getConnection();

//////////////////////////////
			ps = conn.prepareStatement( qGetAuctionTime );

			ps.setInt( 1, auctionID );

			rs = ps.executeQuery();

			if ( rs.next() ) {
				return rs.getInt( "endingTime" );
			}
			else {
				throw new IllegalStateException( "Can't get endingTime" );
			}
//////////////////////////////
		}
		catch ( SQLException e ) {
			System.out.println( "bridge " + e.toString() + e.getStackTrace() );
			throw new DatabaseException( e.toString() );
		}
		finally {
			try { if (rs != null) rs.close(); } catch(Exception e) { }
			try { if (ps != null) ps.close(); } catch(Exception e) { }
			try { if (conn != null) conn.close(); } catch(Exception e) { }
		}
	}