And_One wrote:which file, which query, which function do you mean?
Do you think I was a little bit cryptic? >:D
Aren't we talking about the roster view and about presences stats?
The file is model/roster.php, here the function with the discussed query:
$query=' SELECT sum(IF(mp.came_in=0,1,0)) + sum(IF(mp.came_in=1,1,0)) AS played,
sum(IF(mp.came_in=0,1,0)) AS started,
sum(IF(mp.came_in=1,1,0)) AS sub_in,
sum(IF(mp.out=1,1,0)) AS sub_out,
FROM #__joomleague_match AS m
INNER JOIN #__joomleague_match_player AS mp ON mp.match_id=m.id
INNER JOIN #__joomleague_round r ON m.round_id=r.id
INNER JOIN #__joomleague_project_team AS pt1 ON m.projectteam1_id=pt1.id
INNER JOIN #__joomleague_team_player AS tp ON tp.id=mp.teamplayer_id
INNER JOIN #__joomleague_team AS t1 ON t1.id=pt1.team_id
INNER JOIN #__joomleague_project_team AS pt2 ON m.projectteam2_id=pt2.id
INNER JOIN #__joomleague_team AS t2 ON t2.id=pt2.team_id
INNER JOIN #__joomleague_project AS p ON p.id=r.project_id
AND m.published = 1
AND p.published = 1
AND tp.published = 1
GROUP BY tp.person_id
I think that this query must be revisited, cause with my change it doesn't count rightly presences in case multiple subs in same game, and without my change it doesn't count presences rightly in all cases.
Now I understand that you innerjoin some tables to check if they are published, but what about round table?
Here is zeta, hoping having been more clear and wishing you a good new year (with joomleague 1.5 released)!