473,385 Members | 1,766 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Sort Before Paging

I have about 1,000 records in my XML to be shown. It's too much to
display all of them at once. So, paging is a good implementation.

I'm doing all this at client side, that is,
- xml dataisland
- client-side xslt
- client-side script (Java or VB)
for the purpose of performance and less load at web server.

To achieve paging, Michael Kay has given an example
(http://www.biglist.com/lists/xsl-lis.../msg00142.html)
using

<xsl:param name="M" select="1"/>
<xsl:param name="N" select="20"/>
<xsl:template match="/">
<xsl:apply-templates select="record[position() &gt;= $M and position
&lt;=
$N]"/>
</xsl:template>

Now, supposed users want sorting and paging combined with sorting taking place
first. Since <xsl:sort> is the child element of <xsl:apply-templates>, it
becomes,

....
<xsl:template match="/">
<xsl:apply-templates select="record[position() &gt;= $M and position
&lt;= $N]">
<xsl:sort select="something" order="ascending"/>
</xsl:apply-templates>
</xsl:template>

But doing so will only sort nodes within the page, not overall.

Any clue?

Thanks.
Jul 20 '05 #1
0 1645

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: yellow1912 | last post by:
Ok, lets say I have 1000 items in my database (mysql) and want to display X items per page. I learned to do it by querying with the LIMIT constrain (something like this...
3
by: taly | last post by:
Hi all how can I make the interface for the user so he can sort datagrid? thanks
11
by: Jim McGivney | last post by:
I am trying to sort a web datagrid asp.net. In the sort command I use: private void MyGrid_SortCommand(object source, System.Web.UI.WebControls.DataGridSortCommandEventArgs e) { DataView...
1
by: GP | last post by:
I have created a datagrid that is creating columns dynamically at runtime using the template columns.Edit ,add & delete works fine. The only problem I face is with sorting,I am setting the sorting...
2
by: asad | last post by:
Hello friends, i am designing a ASP.NET page where i want to use custom paging bcoz data is too heavy so pls tell me how can i use custom paging in ASP.NET Thanks
2
by: farhad13841384 | last post by:
Hi , I Hope You fine. I have some problem with this code for paging in asp.net this bottom code work correctly without any error but when I try to place separate code in .VB file then error is...
2
by: rn5a | last post by:
In a shopping cart app, a ASPX page retrieves the order details & personal details of a user from a MS-Access database table depending upon the username of the user. The order details of a...
1
by: Pacific Fox | last post by:
Hi all, I have a SQL statement that allows paging and dynamic sorting of the columns, but what I can't figure out without making the SQL a dynamic string and executing it, or duplicating the SQL...
2
by: gnewsgroup | last post by:
I have a GridView, in which the header of one column changes depending on the selected value of a DropDownList outside of this GridView. I did this dynamic header through protected void...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.