protected synchronized void executeQuieries() {
		
		if (!m_queries.isEmpty())
		{		
			String query = null;
			Statement statement = null;
			
			Connection connection = getConnection();
			try {	
				if (connection == null) {
					Utilities.outputError("Could not connect to database.");
					return;
				}
			
				statement = connection.createStatement();
				
				Iterator<String> queryItr = m_queries.iterator();
				while (queryItr.hasNext()) {
					query = queryItr.next();
					statement.addBatch(query);	
				}
				
				statement.executeBatch();

				statement.close();
				connection.close();
				m_queries.clear();
			} catch (SQLException e) {
				final String errorMessage = e.getMessage().toLowerCase();
				if (!(errorMessage.contains("locking") || errorMessage.contains("locked"))) {
					Utilities.outputError("Batch Exception: Exception whilst executing");
					Utilities.outputError(query);
					e.printStackTrace();
					m_queries.remove(query);
				}	
				try {
					statement.close();
					connection.close();
				} catch (SQLException ce) {}
			}		
		}				
	}