public List<Item> findAllItems() throws Exception {
    if (allItems == null) allItems = connection.prepareStatement(
      "SELECT * FROM ITEMS I1 INNER JOIN ITEMLIVRES L ON L.ITEM = I1.ID UNION " +
      "SELECT * FROM ITEMS I2 INNER JOIN ITEMDVDS M ON M.ITEM = I2.ID UNION " +
      "SELECT * FROM ITEMS I3 INNER JOIN ITEMDISQUES A ON A.ITEM = I3.ID"
    );
    ResultSet rs = allItems.executeQuery();
    List<Item> items = new ArrayList<Item>();
    while (rs.next()) {
      int type = rs.getInt(2);
      if (type == 1) {
        items.add(new AlbumItem(rs));
      } else if (type == 2) {
        items.add(new MovieItem(rs));
      } else if (type == 3) {
        items.add(new BookItem(rs));
      } else {
        items.add(new Item(rs));
      }
    }
    return items;
  }