I have the following database, it's a simple relationship between an user and his receipts:
I need to get as many row as users and so many column as much receipt it have. For example:
If user 1 have 2 receipt I have to obtain:
IdUser Receipt 1 Receipt 2
1 12€ 13€
I tried with an inner joint between User and Receipt tables, but I have as many rows users as receipts they have.
EDIT
SELECT user.idUser, receipt.value
FROM user INNER JOIN receipt ON user.IdUser = receipt.IdUser;