atamashi
New Member
Hi,
I tried to upgrade three tables in a single plugin. I only work the update. I placed first, the next two do not work. I have swapped positions and have verified that only in the first I have of me // works echo $ query-> dump (); exit; I missing? : O I'm doing wrong? Thank you for your help. This is the code:
I tried to upgrade three tables in a single plugin. I only work the update. I placed first, the next two do not work. I have swapped positions and have verified that only in the first I have of me // works echo $ query-> dump (); exit; I missing? : O I'm doing wrong? Thank you for your help. This is the code:
Code:
<?php
// Cheque para asegurar que este archivo se incluye en Joomla!
defined('_JEXEC') or die();
// Get a db connection.
$db = JFactory::getDbo();
// Create a new query object.
$query = $db->getQuery(true);
// Here I have code that calculates // variables for update
//
// Clear down any previous query
$query->clear();
// Update the query to my summary table 'carta_calidad'
// in the fields excelente, muy_bueno, bueno, regular, malo.
$query
->update('carta_medios_pedidos_rechazados')
->set("Por Tel='$porTel', Por email='$porEmail', Personalmente='$personal'")
->where('id IS NOT NULL');
$db->setQuery($query);
//echo $query->dump();exit;
$db->execute();
// Clear down any previous query
$query->clear();
// Update the query to my summary table 'carta_calidad'
// in the fields excelente, muy_bueno, bueno, regular, malo.
$query
->update('carta_tipos_pedidos_rechazados')
->set("Neurolog?a='$neurologia', Neurocirug?a='$neurocirugia', Medicina Interna='$medicinaInterna',
Neuropediatr?a='$neuropediatria', Fisiatr?a='$fisiatria', Psicolog?a='$psicologia',
Neuropsicolog?a='$neuropsicologia', Psiquiatr?a='$psiquiatria', Otro tipo de Cita='$otroTipoCita'")
->where('id IS NOT NULL');
$db->setQuery($query);
$db->execute();
// Clear down any previous query
$query->clear();
// Update the query to my summary table 'carta_calidad'
// in the fields excelente, muy_bueno, bueno, regular, malo.
$query
->update('carta_motivos_pedidos_rechazados')
->set("No Disponibilidad Citas='$noDisponCitas', No atendemos especialidad='$noAtendEspecialidad',
No atendemos el motivo='$noMotivoConsulta', Paciente rechaza por excesiva espera='
$pacienteRechazExcesivaEspera', Otro motivo de Rechazo='$otroMotivoRechazo'")
->where('id IS NOT NULL');
$db->setQuery($query);
$db->execute();
?>