17 | | GROUP_CONCAT(n.Nadzor_Ime SEPARATOR ', ') AS Nadzor_Names |
18 | | FROM |
19 | | Objekt o |
20 | | LEFT JOIN |
21 | | Vo_Izgradba vi ON o.Objekt_ID = vi.Objekt_ID |
22 | | LEFT JOIN |
23 | | Nadgleduva nd ON o.Objekt_ID = nd.Objekt_ID |
24 | | LEFT JOIN |
25 | | Nadzor n ON nd.Nadzor_Ime = n.Nadzor_Ime |
26 | | WHERE |
27 | | o.Objekt_ID = input_Objekt_ID |
28 | | GROUP BY |
29 | | o.Objekt_ID; |
| 17 | n.Nadzor_Ime |
| 18 | FROM Objekt o |
| 19 | LEFT JOIN Vo_Izgradba vi ON o.Objekt_ID = vi.Objekt_ID |
| 20 | LEFT JOIN Nadgleduva nd ON o.Objekt_ID = nd.Objekt_ID |
| 21 | LEFT JOIN Nadzor n ON nd.Nadzor_Ime = n.Nadzor_Ime |
| 22 | WHERE o.Objekt_ID = input_Objekt_ID |
| 23 | GROUP BY o.Objekt_ID; |
46 | | SUM(n.Cena) AS Total_Spent |
47 | | FROM |
48 | | Nabavka n |
49 | | JOIN |
50 | | Nameneta_Za nz ON n.Nabavka_ID = nz.Nabavka_ID |
51 | | JOIN |
52 | | Ispolnuva i ON n.Nabavka_ID = i.Nabavka_ID |
53 | | JOIN |
54 | | Dobavuvac d ON i.Dobavuvac_Ime = d.Dobavuvac_Ime |
55 | | WHERE |
56 | | nz.Objekt_ID = input_Objekt_ID |
57 | | GROUP BY |
58 | | d.Dobavuvac_Ime; |
| 37 | SUM(n.Cena * n.Kolicina) AS Total_Spent |
| 38 | FROM Nabavka n |
| 39 | JOIN Nameneta_Za nz ON n.Nabavka_ID = nz.Nabavka_ID |
| 40 | JOIN Ispolnuva i ON n.Nabavka_ID = i.Nabavka_ID |
| 41 | JOIN Dobavuvac d ON i.Dobavuvac_Ime = d.Dobavuvac_Ime |
| 42 | WHERE nz.Objekt_ID = input_Objekt_ID |
| 43 | GROUP BY d.Dobavuvac_Ime; |