DataFormWebPart: Sorting with Last modified bug

I have created a DataFormWebPart with SPD2013. In my DataFormWebPart, I sort the table by Modifed column. The column is display with follow format:
<xsl:value-of select="ddwrt:FormatDate(string(@Modified), 2057, 5)"/>
However, when sorting with descending order. The time at 12:xx is at higher proirity:
24/04/2015 12:44
24/04/2015 12:25
24/04/2015 17:18
24/04/2015 16:55
24/04/2015 15:52
Why is that? Can we fix it? Thank you.

Thank you for your reply. I have done more test. When I press F5 to refresh the page, the sorting order is correct. However when click on the column header to sort the order is incorrect.
There are only two sentense start with <xsl:sort
<xsl:sort select="*[name() = $dvt_sortfield] | @*[name() = $dvt_sortfield] | text()[name(ancestor::*[1]) = $dvt_sortfield]" order="{$dvt_sortdir}" data-type="{$dvt_sorttype}" />
<xsl:sort select="ddwrt:FormatDate(string(@Modified),2057,5)" order="descending" />
and here is part of column with wrong order when clicking the header:
<xsl:call-template name="dvt.headerfield" ddwrt:atomic="1" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime">
 <xsl:with-param name="fieldname">@Modified</xsl:with-param>
 <xsl:with-param name="fieldtitle">修改時間</xsl:with-param>
 <xsl:with-param name="displayname">修改時間</xsl:with-param>
 <xsl:with-param name="sortable">1</xsl:with-param>
 <xsl:with-param name="fieldtype">x:dateTime</xsl:with-param>
</xsl:call-template>
Here is how the sorting looks like:
24/04/2015 15:52
24/04/2015 16:55
24/04/2015 12:44
27/04/2015 13:49
27/04/2015 13:53

Similar Messages

  • Compare current time and date with last modified?

    Compare current time and date with last modified?
    What is the ideal way to compared the last modified from the File class with the current date and time? last modifed value from File class is a long.

    798642 wrote:
    So what do I do to compare whether the current date and time and later than the lastModified ?
    if(file.lastModified() < System.currentTimeMillis()) {
    Like that?That tests whether the last modified time is before "now"--that is if the file was not modified in the future, so, yes.

  • Why will finder not order files by last modified?

    Finder has an option to arrange files by last modified, which I have enabled: http://i.imgur.com/rOfwz1O.png
    This doesn't do what is says though, it groups files last modified with a particular time frame (today, yesterday, last week, etc.) and shows them alphabetically within that group.
    To illustrate this problem create 3 files, a, b, c
    -rw-r--r-- 1 admin staff 0 11 Oct 13:04 a
    -rw-r--r-- 1 admin staff 0 11 Oct 13:03 b
    -rw-r--r-- 1 admin staff 0 11 Oct 13:04 c
    As you can see 'b' was created a minute before 'a' and 'c', yet in finder with the arrange by last modified option enabled they still appear in alphabetical order: http://i.imgur.com/4cVRTdD.png
    How do I get true chronological ordering of files in OSX?
    Thanks for any help

    By what you describe, it is arranging files by last modified. But, it appears you want to Sort by last modified.
    Set the Arrangement to None, then option click the button (or menu item). It will switch to Sorting options.
    You can set an Arrangement and also sort within the groups of the arrangement.

  • Sort by date modified

    I'm trying to create a smart album containing all the pictures I modified let's say within the last 3 months. Even though there is a dedicated exif field for this information there seems to be no option to include this as a search parameter. correct me if I'm wrong.
    But there has to be a work around.
    Help appreciated.

    Afaik, the "Last Modified Date" is not available in either the Filter HUD or the Smart Settings HUD.
    What I do is create a Smart Album showing all Images, sorted on "Last Modified Date", descending.  I store this Smart Album near the top of my Library Inspector, and select it when I want to review or select from recently modified Images.
    Here is a screenshot showing what I mean:
    To sort by "Last Modified Date", include it in your "List View - Expanded" Metadata Overlay, click that header while in List view, and then change to Grid view.
    I recommend that all users set up "List View - Expanded" to include all metadata fields available.

  • After updating to IOS 8.0.2 on my IPAD2 s Prorked great with last IOS version. Is there a bug fix?

    After updating to IOS 8.0.2 on my IPAD2, I cannot print to my Samsung Wireless Printer. It worked great with last IOS version. Is there a bug fix?

    Try this:
    1. Turn the router, iPad and printer off
    2. Turn on the router and then wait 30 seconds
    3. Turn on printer and then wait 30 seconds
    4. Turn on your iPad and test print.

  • Sorting by Last Name with One Field

    In other words, how would I sort by last name when it's a single field that looks like FirstName_LastName?
    Ex:
    Alex S
    Derek A
    Bob Z
    to
    Derek A
    Alex S
    Bob Z
    I would suppose there is a way to make it read only the data after the space and sort it that way somehow?
    I have other problems but this is the biggest one I have at the moment.

    Dgn wrote:
    The thing is the I don't specifically remember hearing this in class and it doesn't appear in my book unless it goes by some other name.
    I'm dealing with a multi class program if that has any relevance.
    And I'm supposed to sort the names into a alphabetical last name format.Are you supposed to use your own sorting alogrithm or are you supposed to use Java's built in sorting algorithms and API?

  • Sorting with nulls last on the fact column

    anybody tell me how to do the sorting with nulls last in the template? i can't change anything in data model or anywhere other than template.
    i did try to put the descending order,but null values are coming in between positive and negative values.
    <?sort:FACT_Column_Name;'decending';data-type='number'?>
    could anyone please tell me how can i do that in template?
    Thanks in advance.
    Edited by: user12255470 on Apr 12, 2012 5:29 PM

    Hi to all,
    i've solved, is very simple using decode inside the select:
    SELECT
    ID,
    FK_HTMLDB_ITEM, DECODE(FK_HTMLDB_ITEM,1,HTMLDB_ITEM.DATE_POPUP(3,rownum,VAL,'dd-mon-yyyy'),2,HTMLDB_ITEM.TEXT(3,VAL)) VALORE
    FROM TESTID
    my table is:
    CREATE TABLE "DEV"."TESTID"
    (     "ID" NUMBER NOT NULL ENABLE,
         "FK_HTMLDB_ITEM" NUMBER,
         "VAL" VARCHAR2(4000 BYTE))
    Bye Bye

  • When I sync my contacts with Outlook, the iphone shows them sorted by first name.  I want them sorted by last name.

    I have my contacts stored in Outlook (sorted by last name).  When I sync to my Iphone, the contacts are sorted by first name.  I have checked the Settings and show and file are checked as Last, First.  What can I do to change this sort?

    On the phone, go to Settings>Mail, Contacts, Calendars select the account you want and scroll down to the settings for Contacts.  You can change display and sort order there.
    Matt

  • Load file on db with file system last modified date info

    Hi,
    i have e procedure for load a file on my DB table.
    How to write on my table the last modified date read for file system?
    Thanks in advance
    Marc

    Try this example to use dbms_pipe for executing the OS commands to get the last modified date of a file.
    calling shell script from sql procedure

  • "Last Modified" Fields

    Hello All,
    I would appreciate some clarification on the fields "Last modified by" and "Last modified date".
    I have been experiencing a lot of errors regarding these fields. There is a group of projects that i need to open only to run a few reports on regular basis. Even without scheduling or committing any changes in any of those schedules, i have my ID against many of the activities in those projects.
    What is even stranger, is the fact that not all the activities of all these projects that i open have my ID against them.
    My colleagues face similar problems in this organization.
    I would like to know if this is a system bug or am i missing something here?
    Thanks very much.
    Edited by: 953042 on 8/01/2013 18:51

    p0sitive wrote:
    I've noticed it in Finder and iTunes so far. So I'm pretty sure it has to do with the OS.
    All the info in Finder - created/modified/last opened are on 1/5/08 under the Preview section when viewing the files in Finder however when you go to Get Info it shows the correct dates/times.
    For iTunes all my songs are date added on 1/5/08.
    You might see if running DU and repairing HD and permissions helps, but I doubt it.
    Sounds more like a corrupted .plist.
    Try this
    Create a new user - non admin - and see what that user sees for the file dates. If they are corret with the new user, then one of your .plists is bad. No big deal.
    If the dates are also wrong with the new user, then it's most likely a system problem.
    Do you have DiskWarrior?

  • Know an extension that searches for the file "last modified" date?

    I am working on a site with 80,000 pages and need to find an
    extension that will search all files within the site and populate
    the date each file was last modified. Know of an extension that
    will assist in this situation? Any ideas will help, thanks in
    advance!

    Ahh, so now your requirements are changing. You do not want a
    simple
    text file output after all, but instead a sortable list. So
    perhaps
    output as a csv that could be sorted within a spreadsheet.
    Altho 80000
    rows?
    It is a bit hard to believe that an organization with an
    80000 page
    website does not have inhouse gurus who could do this in a
    heart beat.
    E. Michael Brandt
    www.divaHTML.com
    divaGPS | divaFAQ
    www.valleywebdesigns.com
    JustSo PictureWindow
    mercuryfenix wrote:
    > I just finished the first scan and was not impressed.
    PageList creates an ugly
    > and nearly useless list of file name, title, path from
    page root, a link to the
    > file, last modified date and time, and some meta
    garbage. To top it all off,
    > you cannot sort it by any of these categories because it
    puts all the data into
    > a lousy html table- useless.
    > I could probably get buy with this, but it would be
    horrible....80,000 pages
    > to scan! O yeah, i forgot to mention it has a very low
    limit to how many files
    > it can scan in one scan!
    >
    > I still am in need of a better extension. Please keep
    helping.
    >

  • Sorting with Name

    hi
    i have procedure with sorting technic..
    for sorting i have used code like this
    ......select ...... .. select ......  rownum rn from table_name
                             where cond...
             where pagenumber ......  pagesize........
    but now i want display result according to sorting,
    with alphabetic sorting.
    means if a user want to search name like start with name "M"
    i want to display result with starting letter is "M" as follows...
    and also user want to move <<next> <<last>> <<first>> <previouse>>for this any doc's or sample example or any ideas
    Edited by: OraclePLSQL on Dec 30, 2010 5:31 PM

    Hi,
    ROWNUM shows the order in which a row was received.
    If the source of the data is a table, then the order is undefined, and ROWNUM is arbitrary.
    If the source of the data is a sub-query or a view, then ROWNUM reflects the ORDER BY clause of that sub-query or view. If there is no ORDER BY clause, then ROWNUM is arbitrarty.
    If you want a Pagination Query , where you each page has a given size (it looks like 3 in your example), and you want to display only one given page (page #2 in your example), then you can use ROWNUM, but assign ROWNUM after the data is ordered.
    So you could modify the query you posted like this:
    SELECT * FROM
       SELECT ENAME,    EMPNO,    SAL
       ,      ROWNUM   AS RN               -- ROWNUM is meaningful here (source is ordered)
       FROM
         SELECT    ENAME, EMPNO, SAL          -- No ROWNUM here (source is not ordered)
         FROM      EMP
    --   WHERE     ename     LIKE 'M%'          -- Any filtering goes here
         ORDER BY  ename
       WHERE ROWNUM <((2*3)+1)
    WHERE RN >= (((2-1)*3)+1)
    ORDER BY  rn
    ;Remember to use an ORDER BY clause in the main query, if you want the output sorted.
    Output (using scott.emp):
    ENAME           EMPNO        SAL         RN
    CLARK            7782       2450          4
    FORD             7902       3000          5
    JAMES            7900        950          6This is the 2nd page; ADAMS, ALLEN and BLAKE would be on page 1.
    I think the analytic ROW_NUMBER function is better than ROWNUM for this kind of thing.
    Also, consider using variables instead of the "magic numbers" 2 and 3 in your WHERE clauses.
    The following query produces the same results as the query above:
    -- How many rows should appear on each page (except maybe the last page)?
    VARIABLE  page_size     NUMBER
    EXEC  :page_size := 3;
    -- Which page do we want to display in this query?
    VARIABLE  page_num     NUMBER
    EXEC  :page_num  := 2;
    WITH     got_rn     AS
         SELECT     ename, empno, sal
         ,     ROW_NUMBER () OVER (ORDER BY ename)     AS rn
         FROM     emp
    --     WHERE     ename     LIKE 'M%'     -- Any filtering goes here
    SELECT       *
    FROM       got_rn
    WHERE       CEIL (rn / :page_size)     = :page_num
    ORDER BY  rn
    ;

  • Getting the "last modified" property of a file located on HTTP server

    Hello
    I'd like to read a file (on http server) according to his "last modified" time. Can anybody tell me how to get the "last modified" property in a J2ME/CLDC application?
    Thanks in advance

    the file that you want get is in the server?
    you can use java.io.File.lastModified() which in J2SE to get a long num.
    then you can transform long int to orther class that you need ,and do this in server.
    at the end of all you can send this info to J2ME/CLDC app with stream.

  • How can you find the Last Modified Date of a particular table

    Hi,
    I want to show to the LAST MODIFIED date of a particular table to the user before refreshing the table with new data. Experts please suggest me the way using JDBC-SQL connection.

    There is no generic SQL way for this. It depends completely on the features your DBMS offers. With Oracle you'd need to create column which gets updated in a trigger. I believe MS SQL Server offers a special data type for this, which is updated automatically. I don't know about others.

  • No dates in Last Modified Date or Added Date

    Hello.
    Due to some issues with our servers i'm unable to make any SR's so i hope to recive some answers here instead while that issue gets resolved.
    When looking in the colums "Added Date" and "Last Modified Date" certain activites have no dates there. When attempting to filter all the activities with a filter "Added Date Equals 'Blank' " ie all aktivites who do not have a date in Added Date, the results are 0 activites. I interpret this as the fields are not empty but for some reason the information is not displayed.

    781070 wrote:
    Hello.
    Due to some issues with our servers i'm unable to make any SR's so i hope to recive some answers here instead while that issue gets resolved.
    When looking in the colums "Added Date" and "Last Modified Date" certain activites have no dates there. When attempting to filter all the activities with a filter "Added Date Equals 'Blank' " ie all aktivites who do not have a date in Added Date, the results are 0 activites. I interpret this as the fields are not empty but for some reason the information is not displayed.As far back as I can remember, filtering by either of those fields has never worked.
    There are a number of reasons why the last modified or added date could be blank.

Maybe you are looking for