Try Now
More in this section

Forums / Developing with Sitefinity / Paged query problems help.

Paged query problems help.

1 posts, 0 answered
  1. Pierre
    Pierre avatar
    433 posts
    16 Feb 2006
    01 Nov 2010
    Link to this post
    Hi Team,

    I have paged dynamic query returning only page=0 for my requests for a large dataset of items. What is the way to obtain this paged request?.

    public Dataset PagedQuery(int page)
      QueryProduct q1=new QueryProduct();
      int PageMax=20;
      q1.Load(20,page*PageMax);//(max items, from)
      GroupSerialiser gs=new GroupSerialiser();
      QueryProductData q2=new QueryProductData();
      foreach(Product prod in q1)
          q2.OrConditions("ProductID", QueryCondition.EQ, prod.ID)  
      return ds.Data;

    Demand page = 0 --> OK 2 Tables in dataset
    Demand page = 1 or more --> No Data, No Tables in Dataset, schema is emply.
    if use q1.LoadAll() all items are returned >200 items.
    It's like posted only one time to the server and the response have no data corresponding to the page=1 or more the next time demanded. This issue is the same if you append a  .aspx?Cache=random() to the request to force the server to proceed. Advice please.

1 posts, 0 answered