1 ; ConfiguraciĆ³n de la base de datos.
4 obtener_datos_perfil = " SELECT p.id_perfil, p.desc_perfil, p.responsable FROM samurai.perfil as p "
5 obtener_datos_perfil2 = " WHERE p.id_perfil = ? "
6 obtener_datos_perfil3 = " WHERE p.desc_perfil = ?"
7 obtener_id_perfiles = " SELECT ps.id_perfil FROM samurai.perfil_sist as ps, samurai.perfil as p WHERE ps.id_perfil = p.id_perfil "
8 obtener_id_perfiles3 = " AND ps.id_sistema = ? "
9 obtener_id_perfiles2 = " AND p.desc_perfil like '%##FILTRO##%'"
10 obtener_id_perfiles4 = " ORDER BY p.desc_perfil"
11 obtener_id_perfiles5 = " SELECT p.id_perfil FROM samurai.prefil as p "
12 obtener_id_perfiles6 = " WHERE p.desc_perfil like '%##FILTRO##%'"
13 borrar_perfil = " DELETE FROM samurai.perfil as p "
14 obtener_permisos = " SELECT id_permiso, observaciones FROM samurai.perm_perfil_sist WHERE id_perfil = ? AND id_sistema = ?"
16 borrar_permisos = " DELETE FROM samurai.perm_perfil_sist WHERE id_perfil = ? AND id_sistema = ?"
17 borrar_perfil_sist = " DELETE FROM samurai.perfil_sist WHERE id_perfil = ? AND id_sistema = ?"
18 borrar_perfil = " DELETE FROM samurai.perfil WHERE id_perfil = ?"
21 verificar_asociacion = " SELECT ps.id_perfil FROM samurai.perfil_sist as ps WHERE ps.id_perfil = ? AND ps.id_sistema = ?"
22 verif_perfil_sist_usuario = "SELECT IF(0,0,count(*)) as cuenta FROM samurai.perfil_sist_usuario WHERE id_perfil = ? AND id_sistema = ? "
23 verif_perfil_sist = "SELECT IF(0,0,count(*)) as cuenta FROM samurai.perfil_sist WHERE id_perfil = ? "
25 verif_perm_perfil_sist = "SELECT id_sistema, id_perfil, id_permiso, observaciones FROM samurai.perm_perfil_sist WHERE id_sistema = ? ORDER BY id_perfil"