Welcome to Vortx Community Forum, where you can ask questions and receive answers from the staff at Vortx and other members of the community.

If you had a user account on our previous forums website, you will need to register a new account here.

Learn more about...


products stored procedure SQL change sort order

Is there anything built into the products stored procedure sql that allows for changing the sort order of the products? Specifically I want to change it on our entity pages which are using 'entity.gridwithprices' xml pacakge.

At minimum, is it possible to specify addition sort options, like by date added, alphabetically, etc by adjusting any of the query parameters?

Ultimately though, What I really would like to do if possible, is to randomize it so when the page is loaded there are a different set of products every time. is this possible?

asked Jul 28, 2016 in MultiStore by Mden (310 points)

1 Answer

0 votes
'Out of the box' that XML package uses the aspdnsf_GetProducts stored procedure.  The only sorting options that sproc recognizes are 'default' (so it honors the display order you've set on products/entities) and 'bestseller', which sorts as it sounds.

Any other sort options would require some customization to that sproc.  If you open it up and look for references to @sortby you'll see where that should be done.
answered Jul 28, 2016 by Vortx ScottS (13,500 points)