INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1744721810744','7','','0','2025-04-15','2025-04-14','08:00:00','18:00:00','Finalizado','42','42','','-1744721810744','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1744721852032','5','Reunião semanal equipe POA, entrevista presencial em Parobe candidato Maico.\n','0','2025-04-15','2025-04-15','08:00:00','12:00:00','Finalizado','42','42','','-1744721852032','','') - 42;
INSERT INTO agenda_resposta_desenvolvimento_equipe (tarefa, prazo, feedback, acao) values ('-1744721810744','','','') - 42;
INSERT INTO agenda_resposta_desenvolvimento_equipe (tarefa, prazo, feedback, acao) values ('-1744721852032','','','') - 42;
UPDATE agenda_tarefa SET idPrimario = 52234 WHERE idPrimario = -1744721810744 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52234 WHERE tarefa = -1744721810744 - 42;
UPDATE agenda_tarefa SET idPrimario = 52235 WHERE idPrimario = -1744721852032 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52235 WHERE tarefa = -1744721852032 - 42;
update agenda_resposta_formulario a, agenda_tarefa b set a.tarefa = b.id where a.tarefa = b.idOriginal - 42;
update agenda_resposta_desenvolvimento_equipe a, agenda_tarefa b set a.tarefa = b.id where a.tarefa = b.idOriginal - 42;
insert into agenda_tarefa (idPrimario, assunto, vendedor, dataCriacao, dataInsercao, data, horario_inicial, horario_final, usuario, supervisor, idOriginal, observacao, clientes, resumo, status) select date_format(now(),'%Y%m%d%H%i%s') * -1, 999, b.vendedor, curdate(), now(), a.prazo, '08:00:00', '08:00:00', b.supervisor, b.supervisor, date_format(now(),'%Y%m%d%H%i%s') * -1, a.acao, '', '', 'Pendente' FROM agenda_resposta_desenvolvimento_equipe a, agenda_tarefa b where a.tarefaAgendada is null and a.tarefa = b.id ; - 42;
update agenda_tarefa set idPrimario = id where idPrimario = idOriginal; - 42;
update agenda_resposta_desenvolvimento_equipe aa set aa.tarefaAgendada = 1 where aa.tarefaAgendada is null; - 42;
sqlCabecalho-> SELECT a.idPrimario,
f.descricao,
concat(b.supervisor,' - ',g.nome) supervisor,
concat(b.vendedor,' - ',h.nome) vendedor,
DATE_FORMAT(b.data, '%d/%m/%Y') as data,
b.horario_inicial,
b.horario_final,
b.supervisor,
b.vendedor
FROM agenda_tarefa a, agenda_tarefa b
left join agenda_assunto f on b.assunto = f.id
left join vendedor g on b.supervisor = g.id
left join vendedor h on b.vendedor = h.id,
agenda_resposta_formulario c
left join agenda_item d on c.item = d.id
left join agenda_grupo e on d.grupo = e.id
WHERE a.idPrimario = b.id
AND a.id = c.tarefa
AND a.idPrimario = '52234'
GROUP BY a.idPrimario - 42;
Binding output parameters deu certo: ( 0) - 42;
FORM VENDEDOR 20 - 42;
GRUPO->
Grupos:
- 42;
Respostas->Questões:
| Grupo | Questões | Qtd | Percentual |
|---|
- 42;
sqlCabecalho-> SELECT a.idPrimario,
f.descricao,
concat(b.supervisor,' - ',g.nome) supervisor,
concat(b.vendedor,' - ',h.nome) vendedor,
DATE_FORMAT(b.data, '%d/%m/%Y') as data,
b.horario_inicial,
b.horario_final,
b.supervisor,
b.vendedor
FROM agenda_tarefa a, agenda_tarefa b
left join agenda_assunto f on b.assunto = f.id
left join vendedor g on b.supervisor = g.id
left join vendedor h on b.vendedor = h.id,
agenda_resposta_formulario c
left join agenda_item d on c.item = d.id
left join agenda_grupo e on d.grupo = e.id
WHERE a.idPrimario = b.id
AND a.id = c.tarefa
AND a.idPrimario = '52235'
GROUP BY a.idPrimario - 42;
Binding output parameters deu certo: ( 0) - 42;
FORM VENDEDOR 20 - 42;
GRUPO->Grupos:
- 42;
Respostas->Questões:
| Grupo | Questões | Qtd | Percentual |
|---|
- 42;
DELETE FROM agenda_tarefa WHERE idPrimario ='-1739999730793' - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1739999730793','3','','40','2025-02-19','2025-02-19','','','','','42','31195301','-1739999746091','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('51130','3','','100116','2025-02-19','2025-02-19','','','','','42','31480801','-1739999806030','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1739999925279','4','','100116','2025-02-19','2025-02-18','18:00:00','18:30:00','Pendente','40','42','','-1739999925279','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1739999925279','4','','100116','2025-02-19','2025-02-19','','','','','42','31480801','-1739999928818','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1739999962377','2','','100116','2025-02-19','2025-02-18','08:00:00','08:30:00','Pendente','40','42','','-1739999962377','','') - 42;
INSERT INTO agenda_tarefa (idPrimario, assunto, observacao, vendedor, dataCriacao, data, horario_inicial, horario_final, status, usuario, supervisor, clientes, idOriginal, resumo, dataRota) values ('-1739999962377','2','','100116','2025-02-19','2025-02-19','','','','','42','31480801','-1739999966528','','') - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999966528','416','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999966528','417','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999966528','418','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999966528','419','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','101','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','302','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','303','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','106','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','107','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','206','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','305','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','207','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','109','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','110','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','111','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','112','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','114','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','208','1','') ON DUPLICATE KEY UPDATE resposta = '1', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','210','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','115','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
INSERT INTO agenda_resposta_formulario (tarefa, item, resposta, resposta_txt) values ('-1739999806030','117','0','') ON DUPLICATE KEY UPDATE resposta = '0', resposta_txt = '' - 42;
UPDATE agenda_resposta_formulario SET tarefa = 52238 WHERE tarefa = -1739999746091 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52238 WHERE tarefa = -1739999746091 - 42;
UPDATE agenda_resposta_formulario SET tarefa = 52239 WHERE tarefa = -1739999806030 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52239 WHERE tarefa = -1739999806030 - 42;
UPDATE agenda_tarefa SET idPrimario = 52240 WHERE idPrimario = -1739999925279 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52240 WHERE tarefa = -1739999925279 - 42;
UPDATE agenda_resposta_formulario SET tarefa = 52241 WHERE tarefa = -1739999928818 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52241 WHERE tarefa = -1739999928818 - 42;
UPDATE agenda_tarefa SET idPrimario = 52242 WHERE idPrimario = -1739999962377 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52242 WHERE tarefa = -1739999962377 - 42;
UPDATE agenda_resposta_formulario SET tarefa = 52243 WHERE tarefa = -1739999966528 - 42;
UPDATE agenda_resposta_desenvolvimento_equipe SET tarefa = 52243 WHERE tarefa = -1739999966528 - 42;
update agenda_resposta_formulario a, agenda_tarefa b set a.tarefa = b.id where a.tarefa = b.idOriginal - 42;
update agenda_resposta_desenvolvimento_equipe a, agenda_tarefa b set a.tarefa = b.id where a.tarefa = b.idOriginal - 42;
insert into agenda_tarefa (idPrimario, assunto, vendedor, dataCriacao, dataInsercao, data, horario_inicial, horario_final, usuario, supervisor, idOriginal, observacao, clientes, resumo, status) select date_format(now(),'%Y%m%d%H%i%s') * -1, 999, b.vendedor, curdate(), now(), a.prazo, '08:00:00', '08:00:00', b.supervisor, b.supervisor, date_format(now(),'%Y%m%d%H%i%s') * -1, a.acao, '', '', 'Pendente' FROM agenda_resposta_desenvolvimento_equipe a, agenda_tarefa b where a.tarefaAgendada is null and a.tarefa = b.id ; - 42;
update agenda_tarefa set idPrimario = id where idPrimario = idOriginal; - 42;
update agenda_resposta_desenvolvimento_equipe aa set aa.tarefaAgendada = 1 where aa.tarefaAgendada is null; - 42;
statusNaoFinalizado - 42;
statusNaoFinalizado - 42;
statusNaoFinalizado - 42;
statusNaoFinalizado - 42;
statusNaoFinalizado - 42;
statusNaoFinalizado - 42;