public ArrayList<Borrowing> getBorrowingAllBySubject(String subject){
		ArrayList<Borrowing> borrowing = new ArrayList<Borrowing>();
		Statement  stmt;
		ResultSet  rs;
		PreparedStatement ps;
		try
		{
			stmt = con.createStatement();
			//ps = con.prepareStatement("SELECT * FROM borrowing inner join hassubject WHERE borrowing.callNumber = hassubject.callNumber, subject =  ? ORDER BY callNumber");
			ps = con.prepareStatement("SELECT * FROM borrowing ORDER BY callNumber");
			//ps.setString(1, subject);
			rs = ps.executeQuery();
			
			ArrayList<HasSubject> hs = new ArrayList<HasSubject>();
			hs = getHasSubject();

			while(rs.next())
			{
				for (int i = 0; i < hs.size(); i++) {
					String subjectItem = hs.get(i).getSubject();
					String callNumber = hs.get(i).getCallNumber();
					
					if (subjectItem.equals(subject) && callNumber.equals(rs.getString("callNumber"))) {
						Borrowing b = new Borrowing(rs.getInt("borid"),
								rs.getInt("bid"),
								rs.getString("callNumber"), 
								rs.getInt("copyNo"), 
								rs.getString("outDate"), 
								rs.getString("inDate"));
						borrowing.add(b);

					}
				}
				
			}

			stmt.close();
		}
		catch (SQLException ex)
		{
			System.out.println("Message: " + ex.getMessage());
		}	
		return borrowing;
	}