[Building Sakai] Email Archive- sorting by "From" - Sakai trunk

Sobieralski, Damian Michael dsobiera at indiana.edu
Tue May 3 11:14:07 PDT 2011


Hi group,

I am having a problem I hope someone can help me with.  This is in regards
to the email archive and sorting via the UI.  It works fine for subject
and date but doesn't seem to do much for "From".

After digging through the code a bit I notice that for sorting it is
generating SQL and uses an "ORDER BY" to sort.  This works great for
subject and date as they both have database columns.  However, it is
trying to ORDER BY on the column "OWNER" when one tries to sort by "From".
 Looking in the database the column "OWNER" is always set to "postmaster".
 This is for every single record. So this "OWNER" column doesn't seem all
that useful.

So my question for the group is -  should "OWNER" actually be populated
with the emails sender from the XML column?  Maybe I am missing a
configuration setting?  Is anyone else having this issue?

mysql> describe MAILARCHIVE_MESSAGE;
+--------------+--------------+------+-----+---------+-------+
| Field        | Type         | Null | Key | Default | Extra |
+--------------+--------------+------+-----+---------+-------+
| CHANNEL_ID   | varchar(99)  | NO   | PRI | NULL    |       |
| MESSAGE_ID   | varchar(36)  | NO   | PRI | NULL    |       |
| DRAFT        | char(1)      | YES  | MUL | NULL    |       |
| PUBVIEW      | char(1)      | YES  |     | NULL    |       |
| OWNER        | varchar(99)  | YES  |     | NULL    |       |
| MESSAGE_DATE | datetime     | NO   | MUL | NULL    |       |
| XML          | longtext     | YES  |     | NULL    |       |
| SUBJECT      | varchar(255) | YES  | MUL | NULL    |       |
| BODY         | longtext     | YES  |     | NULL    |       |
+--------------+--------------+------+-----+---------+-------+
9 rows in set (0.00 sec)




Thanks, in advance.

- Damian Sobieralski





More information about the sakai-dev mailing list