public DataTable GetAllAreasOHSAS() { string query = "SELECT area,a_descripcion FROM ohsasAreas2 ORDER BY a_descripcion"; try { Sealed_SQL conexion = new Sealed_SQL(); DataTable dt = conexion.EjecutarQuery(query); return(dt); } catch (Exception) { return(null); } }
public DataTable GetIdAreaOHSAS(string numero) { try { string query = "SELECT A.area FROM ohsasMatriz2 AS M INNER JOIN ohsasAreas2 AS A ON M.EMISOR = A.area WHERE M.NUMERO = '" + numero + "'"; Sealed_SQL conexion = new Sealed_SQL(); DataTable dt = conexion.EjecutarQuery(query); return(dt); } catch (Exception) { return(null); } }
/// <summary> /// ESPECIFICOS /// </summary> /// <param name="id_areasealed"></param> /// <returns></returns> public DataTable GetNombreAreasEspecificas(int id_areasealed) { try { string query = "SELECT M.a_descripcion FROM Areas2 AS M WHERE M.area =" + id_areasealed; Sealed_SQL conexion = new Sealed_SQL(); DataTable dt = conexion.EjecutarQuery(query); return(dt); } catch (Exception) { throw; } }