Random Order featured Products |
Post Reply |
Author | |
dwatch
Newbie Joined: 26-February-2006 Status: Offline Points: 33 |
Post Options
Thanks(0)
Posted: 09-September-2006 at 6:55pm |
I replaced the "order by pcprod_OrdInHome asc" with order by NEW(ID)" in the sql query that pulls featured products to display them on home.asp. The goal of course is to randomly show featured products. Anyone have an idea why i am getting an error?
Here is my new sql query:
query="SELECT distinct products.idProduct,products.sku,products.description,product s.price,products.listPrice,products.listHidden,products.serv iceSpec,products.listPrice,products.bToBPrice,products.small ImageUrl, products.pcprod_HideBTOPrice,products.noprices,products.stoc k,products.noStock,products.formQuantity,products.pcProd_Bac kOrder,pcprod_OrdInHome FROM products,categories_products,categories WHERE products.active=-1 AND products.showInHome=-1 AND products.configOnly=0 AND products.removed=0 AND formQuantity = 0 AND categories_products.idProduct=products.idProduct AND categories.idCategory=categories_products.idCategory AND categories.iBTOhide=0 " & query1 & " order by NEWID()" |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |