cancel
Showing results for 
Search instead for 
Did you mean: 

Sorting a table

Former Member
0 Kudos

Hi all,

I need to sort a table based on 'date' field in NW MobileClient for HandHelds.

Here I have written query that retrieves all records of a table in database, I also mentioned 'sortby'

option to '<dateField>' . The query is working fine and records coming in the order I want.

But My problem now is, I want to display the record which is created recently ( may be in same date) as

first record. I am unable to do it as I don't know how to compare time within dates.

Can anyone help me regarding this?

Thanks in advance

Narayana

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello,

I guess it is a DATE type of field so the DB does not have time information. Create a time field next to it and sort on both date and time.

Thank you,

Julien.

Former Member
0 Kudos

HI,

Thanks for your reply. Can you please tell me the statement at ' AddSorting' condition?

I mean I want to know whether date and time fields will be 'Descending'?

If we have one field which contains date and time, then it will be easy to sort it.

If any such type of possibility , please let me know.

Regards

Narayana

Former Member
0 Kudos

Hi,

Yaa.. That's right. I have taken another field which contains time in millisecs.

My problem is solved now.

Regards

Narayana

Answers (0)