public static void deleteschoolaward(Bean beanobj)throws Exception{


		try{ 
			String query1="select * from awardschool where schoolid='"+beanobj.getSchoolid()+"'";
			String query = "delete from awardschool where schoolid='"+beanobj.getSchoolid()+"'";
			con=DBConnection.getConnection();
			pt=con.prepareStatement(query1);
			rs=pt.executeQuery();

			if(rs.next())
			{
				i=1;
				String name=rs.getString(1);
			}
			else
			{
				i=2;
				System.out.println("error");
			}


			pt=con.prepareStatement(query);
			rs=pt.executeQuery();

			con.close();
		}
		catch(Exception e){
			e.printStackTrace();
		}
		finally
		{
			try {
				con.close();
				//pt.close();
			} catch (SQLException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}

		}

	}