DOCUMENTACIÓN OXIPRO
Manual de instrucciones - Base de Datos
 
×
Menú
Índice
 

2.3.3. bi_ubicaciones_paciente

 
Nombre de la tabla en Redash:
bi_ubicaciones_paciente
Nombre de la tabla en BD:
bi_ubicacionespaciente
Descripción del objetivo de la Tabla:
Muestra la información de la ubicación o direcciones de pacientes.
Tipo de tabla:
Maestra - En linea
Fecha versión actual:
14-Junio-2020
Declaración SQL:
SELECT vtiger_ubicacionespacientes.ubicacionespacientesid,
       vtiger_ubicacionespacientes.nombreubicacion,
       vtiger_ubicacionespacientes.paciente,
       vtiger_ubicacionespacientes.tipodomicilio,
       vtiger_ubicacionespacientes.parentezco,
       vtiger_ubicacionespacientes.propiedadhome,
       vtiger_ubicacionespacientes.responsabledom,
       vtiger_ubicacionespacientes.phone,
       vtiger_ubicacionespacientes.celular,
       vtiger_ubicacionespacientes.direccion,
       vtiger_ubicacionespacientes.pais,
       vtiger_ubicacionespacientes.departamento,
       vtiger_ubicacionespacientes.ciudad,
       vtiger_ubicacionespacientes.localidad,
       vtiger_ubicacionespacientes.zona,
       vtiger_ubicacionespacientes.barrio,
       vtiger_ubicacionespacientes.indicacionesadd,
       vtiger_ubicacionespacientes.ubicacionactual,
       vtiger_ubicacionespacientes.accessibility,
       vtiger_ubicacionespacientes.obsaccessibility,
       vtiger_ubicacionespacientes.longitud,
       vtiger_ubicacionespacientes.latitud,
       vtiger_ubicacionespacientes.fechacaptura,
       vtiger_ubicacionespacientes.conductorcaptura,
       vtiger_ubicacionespacientes.auxiliarcaptura,
       vtiger_ubicacionespacientes.coordenadasaprobadas,
       vtiger_ubicacionespacientes.fechaaprobacion,
       vtiger_ubicacionespacientes.useraprobador,
       vtiger_ubicacionespacientes.tiempomunicipio,
       vtiger_ubicacionespacientes.contacto,
       vtiger_ubicacionespacientes.tipoviaprimaria,
       vtiger_ubicacionespacientes.numeroviaprincipal,
       vtiger_ubicacionespacientes.letraviaprincipal,
       vtiger_ubicacionespacientes.bis,
       vtiger_ubicacionespacientes.numeroviageneradora,
       vtiger_ubicacionespacientes.letraviageneradora,
       vtiger_ubicacionespacientes.numeroplaca,
       vtiger_ubicacionespacientes.sur_este,
       vtiger_ubicacionespacientes.listacomplemento,
       vtiger_ubicacionespacientes.valorcomplemento,
       vtiger_ubicacionespacientes.motivociliespecial,
       vtiger_ubicacionespacientes.ciliespecial,
       vtiger_ubicacionespacientes.ubicacionactiva,
       vtiger_ubicacionespacientes.direccion_por_partes,
       vtiger_ubicacionespacientes.complemento_direccion,
       vtiger_ubicacionespacientes.tipificacion_desact_ubic,
       vtiger_ubicacionespacientes.bisviageneradora,
       vtiger_ubicacionespacientes.sur_este_principal,
       vtiger_ubicacionespacientes.este,
       vtiger_barrios.zona AS ba_zona,
       vtiger_barrios.localidad AS ba_localidad,
       vtiger_barrios.departamento AS ba_depto,
       vtiger_barrios.ciudad AS ba_ciudad,
       vtiger_barrios.barrio AS ba_barrio,
       vtiger_pacientesii.identificador_paciente AS NombrePaciente,
       vtiger_pacientesii.docid AS DocumentoPaciente,
       DATE_FORMAT(vtiger_crmentity.createdtime, '%Y%m') AS agno_mes,
       DATE_FORMAT(vtiger_crmentity.createdtime, '%Y%m%d') AS agno_mes_dia,
       yearweek(vtiger_crmentity.createdtime, 0) AS agno_semana,
       vtiger_crmentity.createdtime AS FechaCreacion,
       vtiger_crmentity.smcreatorid AS IdCreadoPor,
       vtiger_users.user_name AS UsuarioCreador,
       CONCAT(vtiger_users.first_name, " ", vtiger_users.last_name) AS CreadoPor
LEFT JOIN vtiger_barrios ON vtiger_ubicacionespacientes.barrio = vtiger_barrios.barriosid
LEFT JOIN vtiger_pacientesii ON vtiger_pacientesii.pacientesiiid = vtiger_ubicacionespacientes.paciente
LEFT JOIN vtiger_crmentity ON vtiger_crmentity.crmid = vtiger_ubicacionespacientes.ubicacionespacientesid
LEFT JOIN vtiger_users ON vtiger_users.id = vtiger_crmentity.smcreatorid
WHERE vtiger_ubicacionespacientes.paciente IS NOT NULL
  AND vtiger_ubicacionespacientes.paciente!=0 and  vtiger_ubicacionespacientes.ubicacionactual = '1'
Tablas involucradas:
  •  vtiger_ubicacionespacientes (Ubicaciones de pacientes).
  •  vtiger_crmentity (Creación).
  •  vtiger_users (Usuarios).
  •  vtiger_pacientesii (Datos de pacientes).
  •  vtiger_barrios (Barrios).
Columnas involucradas:
  •  vtiger_ubicacionespacientes.ubicacionespacientesid (ID de la ubicación del paciente).
  •  vtiger_ubicacionespacientes.nombreubicacion (Nombre de la ubicación).
  •  vtiger_ubicacionespacientes.paciente (ID del paciente).
  •  vtiger_ubicacionespacientes.tipodomicilio (Tipo de domicilio).
  •  vtiger_ubicacionespacientes.parentezco (Parentezco).
  •  vtiger_ubicacionespacientes.propiedadhome (Tipo de propiedad).
  •  vtiger_ubicacionespacientes.responsabledom (Responsable del domicilio).
  •  vtiger_ubicacionespacientes.phone (Número de telefono).
  •  vtiger_ubicacionespacientes.celular (Número de celular).
  •  vtiger_ubicacionespacientes.direccion (Dirección).
  •  vtiger_ubicacionespacientes.pais (Nombre del pais)
  •  vtiger_ubicacionespacientes.departamento (Departamento).
  •  vtiger_ubicacionespacientes.ciudad (Ciudad)
  •  vtiger_ubicacionespacientes.localidad (Localidad).
  •  vtiger_ubicacionespacientes.zona (Zona)
  •  vtiger_ubicacionespacientes.barrio (Barrio).
  •  vtiger_ubicacionespacientes.indicacionesadd (Indicaciones).
  •  vtiger_ubicacionespacientes.ubicacionactual (Ubicación actual).
  •  vtiger_ubicacionespacientes.accessibility (Accesibilidad).
  •  vtiger_ubicacionespacientes.obsaccessibility (Observaciones de accesibilidad).
  •  vtiger_ubicacionespacientes.longitud (Longitud).
  •  vtiger_ubicacionespacientes.latitud (Latitud).
  •  vtiger_ubicacionespacientes.fechacaptura (Fecha de captura).
  •  vtiger_ubicacionespacientes.conductorcaptura (Captura del conductor).
  •  vtiger_ubicacionespacientes.auxiliarcaptura (Captura auxiliar).
  •  vtiger_ubicacionespacientes.coordenadasaprobadas (Coordenadas aprobadas).
  •  vtiger_ubicacionespacientes.fechaaprobacion (Fecha de aprobación).
  •  vtiger_ubicacionespacientes.useraprobador (Usuario aprobador).
  •  vtiger_ubicacionespacientes.tiempomunicipio (Tiempo municipio).
  •  vtiger_ubicacionespacientes.contacto (Contacto).
  •  vtiger_ubicacionespacientes.tipoviaprimaria (Tipo via primaria).
  •  vtiger_ubicacionespacientes.numeroviaprincipal (Número vía principal).
  •  vtiger_ubicacionespacientes.letraviaprincipal (Letra via principal).
  •  vtiger_ubicacionespacientes.bis (Bis).
  •  vtiger_ubicacionespacientes.numeroviageneradora (Número via generadora).
  •  vtiger_ubicacionespacientes.letraviageneradora (Letra vía generadora).
  •  vtiger_ubicacionespacientes.numeroplaca (Número de placa).
  •  vtiger_ubicacionespacientes.sur_este
  •  vtiger_ubicacionespacientes.listacomplemento (Lista complemento).
  •  vtiger_ubicacionespacientes.valorcomplemento (Valor complemento).
  •  vtiger_ubicacionespacientes.motivociliespecial.
  •  vtiger_ubicacionespacientes.ciliespecial.
  •  vtiger_ubicacionespacientes.ubicacionactiva.
  •  vtiger_ubicacionespacientes.direccion_por_partes.
  •  vtiger_ubicacionespacientes.complemento_direccion.
  •  vtiger_ubicacionespacientes.tipificacion_desact_ubic.
  •  vtiger_ubicacionespacientes.bisviageneradora.
  •  vtiger_ubicacionespacientes.sur_este_principal.
  •  vtiger_ubicacionespacientes.este.
  •  vtiger_barrios.zona (Zona del barrio).
  •  vtiger_barrios.localidad (Localidad).
  •  vtiger_barrios.departamento (Departamento del barrio).
  •  vtiger_barrios.ciudad (Ciudad del barrio).
  •  vtiger_barrios.barrio (Nombre del barrio).
  •  vtiger_pacientesii.identificador_paciente (Identificador paciente).
  •  vtiger_pacientesii.docid (Documento paciente).
  •  DATE_FORMAT(vtiger_crmentity.createdtime, '%Y%m') (Fecha de creación, año y mes).
  •  DATE_FORMAT(vtiger_crmentity.createdtime, '%Y%m%d') (Fecha de creación, año, mes y día).
  •  yearweek(vtiger_crmentity.createdtime, 0) (Fecha de creación, año y semana).
  •  vtiger_crmentity.createdtime (Fecha de creación).
  •  vtiger_crmentity.smcreatorid (ID del creador).
  •  vtiger_users.user_name (Usuario creador).
  •  CONCAT(vtiger_users.first_name, " ", vtiger_users.last_name) (Nombre del creador).
Ubicación (URL) en Redash:
Ubicación (RUTA) en base de datos:
206.189.187.192/CRM/Views/bi_ubicacionespacientes
Especificaciones técnicas de los campos involucrados:
Tiempo de ejecución CRON: