optimized. events_has_extended_info

Former-commit-id: 805b80f1a9e09425b0e5710906886ae39e791753
This commit is contained in:
fbsanchez 2019-02-13 15:54:40 +01:00
parent 738443445c
commit 453c639c53
1 changed files with 3 additions and 4 deletions

View File

@ -2622,10 +2622,9 @@ function events_has_extended_info(int $id_event)
{
return (bool) db_get_value_sql(
sprintf(
'
SELECT count(*) as "n"
FROM tevent_extended WHERE id_evento=%d
',
'SELECT count(*) FROM (
SELECT * as "n"
FROM tevent_extended WHERE id_evento=%d LIMIT 1) t',
$id_event
)
);