public static Showlist<Books> Serchbook(String sbook)
			throws NamingException, SQLException {
		Connection conn = null;
		PreparedStatement stmt = null;
		ResultSet rs = null;
		if (sbook == null) {
			sbook = "";
		} else {
			sbook = "%" + sbook + "%";
		}

		DataSource ds = getDataSource();
		Showlist<Books> result = new Showlist<Books>();

		try {
			conn = ds.getConnection();
			stmt = conn
					.prepareStatement("SELECT * FROM books where b_name like ?");
			stmt.setString(1, sbook);

			rs = stmt.executeQuery();

			while (rs.next()) {
				result.getList().add(
						new Books(rs.getInt("b_number"),
								rs.getString("b_name"), rs.getString("writer"),
								rs.getString("maker"), rs.getDate("b_date"), rs
										.getString("category"), rs
										.getInt("isbn"), rs
										.getString("location")));
			}
		} finally {
			if (rs != null)
				try {
					rs.close();
				} catch (SQLException e) {
				}
			if (stmt != null)
				try {
					stmt.close();
				} catch (SQLException e) {
				}
			if (conn != null)
				try {
					conn.close();
				} catch (SQLException e) {
				}
		}

		return result;
	}