====== 2.2 Query con Tabelle Collegate ======
Query SQL sui dati Gateway in Access.
===== Query Semplice =====
SELECT * FROM Customers
WHERE Country = 'Germany'
ORDER BY Name;
===== Join =====
SELECT c.Name, o.OrderDate, o.Total
FROM Customers AS c
INNER JOIN Orders AS o ON c.Id = o.CustomerId
WHERE o.OrderDate > #2024-01-01#;
===== Suggerimento Performance =====
I filtri vengono inoltrati al server - grandi quantita di dati non vengono caricate localmente.
===== Aggregazioni =====
SELECT Country, COUNT(*) AS Conteggio
FROM Customers
GROUP BY Country;