Commit 55f9157e by Denys Tito Urbano

[EDIT] Parametro lista_matricula_id para el endpoint execute_redes

parent 1428f62a
...@@ -245,12 +245,15 @@ public class PostgreSqlExcel implements ExcelDAO { ...@@ -245,12 +245,15 @@ public class PostgreSqlExcel implements ExcelDAO {
try { try {
String p_tipo_vista = json.getString("p_tipo_vista"); String p_tipo_vista = json.getString("p_tipo_vista");
JSONArray lista_matricula_id = json.optJSONArray("lista_matricula_id");
String lista_matricula_id_string = lista_matricula_id == null ? null : lista_matricula_id.toString();
conexion = PostgreSqlFactoryDAO.obtenerConexion("siiaa"); conexion = PostgreSqlFactoryDAO.obtenerConexion("siiaa");
String sql = "SELECT * FROM matricula.func_redes_sociales(?)"; String sql = "SELECT * FROM matricula.func_redes_sociales ( ?, ? :: JSON )";
PreparedStatement ps = conexion.prepareStatement(sql); PreparedStatement ps = conexion.prepareStatement(sql);
ps.setString(1, p_tipo_vista); ps.setString(1, p_tipo_vista);
ps.setString(2, lista_matricula_id_string);
ResultSet rs = ps.executeQuery(); ResultSet rs = ps.executeQuery();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment