Hi,
When you follow this link you see there is a long list of Model: 9500 Communicator.
Is it possible to filter it to one product.
Thx Henk :)
Hi David,
I tried that but then when i import 4500 products there will be 45 over.
Double names problem.
Thx
Henk
Hi Henk,
Perhaps you can combine 2 fields with the Text After filter to get more products but less than the original results. Model Number + Network is often used on mobile phone sites, so by registering Model Number as the product name you could setup a Text After filter something like:
%NETWORK%
Cheers,
David.
Yes i could do that but then the compare is gone by product model and i want that also.
Its now comparing by name and or model.
So is it possible to filter by model also :)
Thx HEnk
Hi Henk,
I'm afraid I'm not quite sure what you're wanting to do here. Do you mean to add the "model" field as an option in the drop-down box on the filters page, so that you can use Drop Record against it?
Cheers,
David.
Hi David,
No when you look at the link there are a lot of model: 9500 Communicator
Is it possible to filter it to one result.
Thx Henk
Hi Henk,
Is "model" a field in your database (I know you have made changes to your field)? It might be possible to add a DISTINCT clause to the search SQL...
Cheers,
David.
Hi David,
Yes its a field in the database.
Thx
Henk
Hi Henk,
The SQL to perform the product selection for a category: query is on line 45 of search.php in the distribution:
$sql = "SELECT * , MIN( price ) AS minPrice, MAX( price ) AS maxPrice, COUNT( id ) AS numMerchants FROM `".$config_databaseTablePrefix."products` WHERE ".$where." GROUP BY name";
To enforce a distinct model number, try changing this as follows:
$sql = "SELECT * , DISTINCT(model), MIN( price ) AS minPrice, MAX( price ) AS maxPrice, COUNT( id ) AS numMerchants FROM `".$config_databaseTablePrefix."products` WHERE ".$where." GROUP BY name";
Alternatively, this may provide better results:
$sql = "SELECT * , MIN( price ) AS minPrice, MAX( price ) AS maxPrice, COUNT( id ) AS numMerchants FROM `".$config_databaseTablePrefix."products` WHERE ".$where." GROUP BY name,model";
Cheers,
David.
i got two errors,
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/httpd/vhosts/linkik.com/subdomains/telecomvergelijk/httpdocs/includes/database.php on line 21
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/httpd/vhosts/linkik.com/subdomains/telecomvergelijk/httpdocs/includes/database.php on line 26
Henk
Thanks Henk, i'll have more of a think on this one...
Hi Henk,
Just had a look at the page, and there is (of course) difference in all the product names which accounts for the long list.
Seeing as the phone network is shown in the description ("Contractduur:") would it be possible to register your model field as the product name instead of the actual combined product name?
Cheers,
David.