String subselect = "id in (select media_id from " + theTable + " where content_id=" + id+")";
try {
- returnList = DatabaseMedia.getInstance().selectByWhereClause(subselect,-1);
+ // media should stay in uploaded order. this is especially important
+ // for photo stories which require a specific chronologic order.
+ // this is why we have the the second parameter "id"
+ returnList = DatabaseMedia.getInstance().selectByWhereClause(subselect,"id",-1);
} catch (Exception e) {
theLog.printDebugInfo("-- get media failed " + e.toString());
throw new StorageObjectException("-- get media failed " + e.toString());
String subselect = "id in (select media_id from " + theTable + " where content_id=" + id+")";
try {
- returnList = DatabaseAudio.getInstance().selectByWhereClause(subselect,-1);
+ // media should stay in uploaded order. this is especially important
+ // for photo stories which require a specific chronologic order.
+ // this is why we have the the second parameter "id"
+ returnList = DatabaseAudio.getInstance().selectByWhereClause(subselect,"id",-1);
} catch (Exception e) {
theLog.printDebugInfo("-- get audio failed " + e.toString());
throw new StorageObjectException("-- get audio failed " + e.toString());
String subselect = "id in (select media_id from " + theTable + " where content_id=" + id+")";
try {
- returnList = DatabaseVideo.getInstance().selectByWhereClause(subselect,-1);
+ // media should stay in uploaded order. this is especially important
+ // for photo stories which require a specific chronologic order.
+ // this is why we have the the second parameter "id"
+ returnList = DatabaseVideo.getInstance().selectByWhereClause(subselect,"id",-1);
} catch (Exception e) {
theLog.printDebugInfo("-- get video failed " + e.toString());
throw new StorageObjectException("-- get video failed " + e.toString());
String subselect = "id in (select media_id from " + theTable + " where content_id=" + id+")";
try {
- returnList = DatabaseImages.getInstance().selectByWhereClause(subselect,-1);
+ // media should stay in uploaded order. this is especially important
+ // for photo stories which require a specific chronologic order.
+ // this is why we have the the second parameter "id"
+ returnList = DatabaseImages.getInstance().selectByWhereClause(subselect,"id",-1);
} catch (Exception e) {
theLog.printDebugInfo("-- get images failed " + e.toString());
throw new StorageObjectException("-- get images failed " + e.toString());
" where content_id=" + id+")";
try {
+ // media should stay in uploaded order. this is especially important
+ // for photo stories which require a specific chronologic order.
+ // this is why we have the the second parameter "id"
returnList = DatabaseOther.getInstance().selectByWhereClause(subselect,
"id");
} catch (Exception e) {