Julian Posted December 6, 2006 Share Posted December 6, 2006 HiI have this query:$query_list = "SELECT edicion.id_edicion AS id_edicion, volumen.volumen AS volumen, edicion.id_volumen AS id_volumen, edicion.title AS title, edicion.edicion AS edicion, edicion.main AS main ";$query_list .= "FROM edicion ";$query_list .= "INNER JOIN volumen ON edicion.id_volumen=volumen.id_volumen ";$query_list .= "ORDER BY edicion ASC ";What I'm missing here is that I want to show only records that are different in `edicon` column.Thanks for the help. Quote Link to comment Share on other sites More sharing options...
joquius Posted December 6, 2006 Share Posted December 6, 2006 SELECT DISTINCT `field` FROM...this is what you mean? Quote Link to comment Share on other sites More sharing options...
Psycho Posted December 6, 2006 Share Posted December 6, 2006 $query_list = "SELECT edicion.id_edicion AS id_edicion, volumen.volumen AS volumen, edicion.id_volumen AS id_volumen, edicion.title AS title, edicion.edicion AS edicion, edicion.main AS main ";$query_list .= "FROM edicion ";$query_list .= "INNER JOIN volumen ON edicion.id_volumen=volumen.id_volumen ";[b]$query_list .= "GROUP BY edicion";[/b]$query_list .= "ORDER BY edicion ASC "; Quote Link to comment Share on other sites More sharing options...
Julian Posted December 6, 2006 Author Share Posted December 6, 2006 Thanks mjdamatoThat is what I was looking for. Worked great Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.