Re: [PHP] Limit query results

2007-05-04 Thread Jim Lucas
Dan Shirah wrote: $result = mssql_query($sql) or die(mssql_error()); // print_r ($result); You realize that this will print the Resource ID# for the resource pointer, but not the actual result set. -- Jim Lucas "Some men are born to greatness, some achieve greatness, and

Re: [PHP] Limit query results

2007-05-04 Thread Miguel J. Jiménez
Use "SELECT DISTINCT" in your SQL syntax. -- Miguel J. Jiménez Programador Senior Área de Internet/XSL/PHP [EMAIL PROTECTED] ISOTROL Edificio BLUENET, Avda. Isaac Newton nº3, 4ª planta. Parque Tecnológico Cartuja '93, 41092 Sevilla. Teléfono:

Re: [PHP] Limit query results

2007-05-04 Thread Zoltán Németh
SELECT DISTINCT? greets Zoltán Németh 2007. 05. 4, péntek keltezéssel 08.44-kor Dan Shirah ezt írta: > Good Morning everyone. > > In the below code I am pulling records from two tables. the records are > tied together by a common key in a 3rd table. Everything works correctly > down to the $re

Re: [PHP] Limit query results

2007-05-04 Thread Fredrik Thunberg
"GROUP BY whatever_id_you_want" in the SQL Dan Shirah skrev: Good Morning everyone. In the below code I am pulling records from two tables. the records are tied together by a common key in a 3rd table. Everything works correctly down to the $result. // Connect to the database $connection =

[PHP] Limit query results

2007-05-04 Thread Dan Shirah
Good Morning everyone. In the below code I am pulling records from two tables. the records are tied together by a common key in a 3rd table. Everything works correctly down to the $result. // Connect to the database $connection = mssql_pconnect($host, $user, $pass) or die ('server connection