I was looking joomla's documentation and they said that for security i should use:
// For SQL data types: INT, INTEGER, TINYINT, SMALLINT, MEDIUMINT, BIGINT, YEAR
$query = 'SELECT *
WHERE `id`=' . (int) $id;
In the field SQL I try :
WHERE id_user_music = '.(int) $cck->getValue('cck_author_id');
I have the following error :
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ''.(int) 1046'
1046 is the ID of cck_author_id.
What is the correct way to add integer to value please.