i’m trying to order a returned set, but i’m having a hard time getting it to order properly.
i’m selecting fields, and each field has a date_updated and a date_added.
when the field is added, the date_updated is null, until there is an update, which it then assigns the current date.
i need to order my list by having the most recent entries be on the BOTTOM, and oldest on the top. so if a item is added, it should go directly to the bottom. is there a way to join all the date fields together, and then just sort by oldest to newest, disregarding update or added?
this may sound kind of confusing, but i’ve already tried numerous combinations of ORDER BY date_added DESC, date_updated ASC, and things like that, but it’s not doing what I need it to do. i get the top portion ordered by date_added and then under that is a separate ordering for date_updated…
any input would be really helpful here…
try
COALESCE DOC