Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Many-to-many SELECT
Salvation
post 2.05.2016, 15:49:29
Post #1





Grupa: Zarejestrowani
Postów: 400
Pomógł: 71
Dołączył: 15.07.2014

Ostrzeżenie: (0%)
-----


Cześć. Po raz kolejny proszę o pomoc smile.gif
Mam takie tabele:
Kod
users(`id_user`, `name`)
users_groups(`id_user`, `id_group`)
groups(`id_group`, `name`)


Mam też takie zapytanie: http://pastebin.com/A8k0NMGN

Problem polega na tym, że chciałbym otrzymać coś takiego:
Kod
[0] => Array
        (
            [id_user] => 1
            [groups] => Array
            (
                [id_group] => 1,2
                [name] => nazwa,nazwa2
            )
        )
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 19.07.2025 - 01:55