Lines Matching refs:tables
579 $tables = [];
603 if (!isset($tables[$key])) {
604 $tables[$key] = 'T' . (++$cnt);
605 $from .= ' LEFT JOIN data AS ' . $tables[$key] . ' ON ' . $tables[$key] . '.pid = W1.pid';
606 $from .= ' AND ' . $tables[$key] . ".key = " . $sqlite->getPdo()->quote($key);
616 $select[] = "pages.page || '|' || GROUP_CONCAT_DISTINCT(" . $tables[$key] . ".value,'\n')";
620 $select[] = 'GROUP_CONCAT_DISTINCT(" " || ' . $tables[$key] . ".value,'\n')";
640 if (!$tables[$col]) {
641 $tables[$col] = 'T' . (++$cnt);
642 $from .= ' LEFT JOIN data AS ' . $tables[$col] . ' ON ' . $tables[$col] . '.pid = W1.pid';
643 $from .= ' AND ' . $tables[$col] . ".key = " . $sqlite->getPdo()->quote($col);
646 $order = 'ORDER BY ' . $tables[$col] . '.value ' . $data['sort'][1];