User Profile

Collapse

Profile Sidebar

Collapse
yakatz
yakatz
Last Activity: Jul 11 '08, 03:30 PM
Joined: Jul 1 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • yakatz
    replied to Dynamic ORDER BY
    I'm sorry, but I did not understand your answer.
    I am writing a package that will create the sorting method seen from the front-end.
    I have an xml package that runs a sql query and formats the results.
    It will take request parameters from the query string and put them in a sql variables. i have the following query string: product.aspx?so rt=1
    which is converted by a static list to the required columns to sort (in this case...
    See more | Go to post
    Last edited by yakatz; Jul 2 '08, 02:41 PM. Reason: add details

    Leave a comment:


  • yakatz
    started a topic Dynamic ORDER BY

    Dynamic ORDER BY

    I am working on adding sorting functionality to an online store.
    The query works fine when it has a hard coded ORDER BY, but not when the ORDER BY is a variable.

    Code:
    declare @CatID Int
    declare @PageSize Int
    declare @PageNumber Int
    declare @OrderBy VarChar
    declare @EntityName VarChar
    
    set @CatID = 3158
    set @PageSize = 10
    set @PageNumber = 1
    set @OrderBy = 'p.SalePrice'
    ...
    See more | Go to post
No activity results to display
Show More
Working...