Darkness Soul Posted April 26, 2006 Share Posted April 26, 2006 Hi Guys,Well, mysql is not my speciality, so, what I'm done wrong?D.SoulError:[code]#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'ONtbCatalogo_Produtos.id_subdepartamento = tbCatalogo_Subdepa [/code]Code:[code]SELECT tbCatalogo_Produtos.id AS id, tbCatalogo_Produtos.titulo AS tituloFROM tbCatalogo_Departamentos INNER JOIN ( tbCatalogo_Subdepartamentos INNER JOIN ( tbCatalogo_Produtos ON tbCatalogo_Produtos.id_subdepartamento = tbCatalogo_Subdepartamentos.id ) ON tbCatalogo_Subdepartamentos.id_departamento = tbCatalogo_Departamentos.id ) ON tbCatalogo_Departamentos.id = 2WHERE tbCatalogo_Subdepartamentos.id = 5[/code] Link to comment https://forums.phpfreaks.com/topic/8486-inner-join/ Share on other sites More sharing options...
fenway Posted April 27, 2006 Share Posted April 27, 2006 This is probably a scoping issue.... what's with all the parentheses? Link to comment https://forums.phpfreaks.com/topic/8486-inner-join/#findComment-31192 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.