Slim Application Error

The application could not run because of the following error:

Details

Type: ErrorException
Code: 2
Message: pg_query(): Query failed: ERROR: una subconsulta utilizada como expresión retornó más de un registro CONTEXT: sentencia SQL: «SELECT (select 'GR'||mg.cod_grupo from sid_materias_grupo mg where mg.cod_materia like par_materia)» función PL/pgSQL fn_ws_programas_con_catedra_pdf(character varying,text) en la línea 14 en asignación
File: /var/www/html/sig/rest/index.php
Line: 26

Trace

#0 [internal function]: Slim\Slim::handleErrors(2, 'pg_query(): Que...', '/var/www/html/s...', 26, Array)
#1 /var/www/html/sig/rest/index.php(26): pg_query(Resource id
#12, 'select * from f...')
#2 [internal function]: {closure}()
#3 /var/www/html/sig/rest/libs/Slim/Route.php(468): call_user_func_array(Object(Closure), Array)
#4 /var/www/html/sig/rest/libs/Slim/Slim.php(1357): Slim\Route->dispatch()
#5 /var/www/html/sig/rest/libs/Slim/Middleware/Flash.php(85): Slim\Slim->call()
#6 /var/www/html/sig/rest/libs/Slim/Middleware/MethodOverride.php(92): Slim\Middleware\Flash->call()
#7 /var/www/html/sig/rest/libs/Slim/Middleware/PrettyExceptions.php(67): Slim\Middleware\MethodOverride->call()
#8 /var/www/html/sig/rest/libs/Slim/Slim.php(1302): Slim\Middleware\PrettyExceptions->call()
#9 /var/www/html/sig/rest/index.php(71): Slim\Slim->run()
#10 {main}