A PHP Error was encountered

Severity: Notice

Message: Undefined index: id

Filename: controllers/Cliente.php

Line Number: 501

Backtrace:

File: /var/www/clients/client2/web29/web/application/controllers/Cliente.php
Line: 501
Function: _error_handler

File: /var/www/clients/client2/web29/web/index.php
Line: 292
Function: require_once

Database Error

A Database Error Occurred

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'ORDER BY e.id DESC' at line 15

SELECT e.*, a.user, a.email, a.bloqueado, es.nome AS nome_estado, c.cidade AS nome_cidade, at.descricao AS nome_atividade FROM empresa e INNER JOIN admin a ON ( e.id = a.id_emp ) INNER JOIN estados es ON (e.id_estado = es.id) INNER JOIN cidades c ON (e.id_cidade = c.cod) INNER JOIN atividades at ON (e.id_atividade = at.id) WHERE a.id = ORDER BY e.id DESC

Filename: models/Cliente_model.php

Line Number: 165