You need to sign in to do that
Don't have an account?
DanielJimenez
Filtering out ids from feedtrackedchanges?
Hi, I'm using a custom controller to grab the chatter feed for a specific object. Here is my query:
select Id, ParentId, CreatedBy.name, CreatedDate, FeedPost.Body, Type, FeedPost.Title, FeedPost.LinkURL, (select FeedItemId, FieldName, OldValue, NewValue from FeedTrackedChanges) from CaseFeed where ParentId = :theCase.id order by CreatedDate desc
Almost everything works great. What I don't like is that FeedTrackedChanges gives you the IDs back with the other field changes. Can anyone give me some pointers on the best way to filter this out? The only idea I had was filtering out anything with a length of 15 or 18 characters. Seems risky though. FWIW, I am using a custom controller.
Thanks in advance!
Daniel
DanielJimenez
Wow, actually VisualForce won't let you do LEN() on FeedTrackedChanges.OldValue or FeedTrackedChanges.NewValue. I get a message saying "Incorrect parameter for function LEN(). Expected Text, received Object". So it seems there is no simple way to filter this out? Argh!
DanielJimenez
Of course the correct way to do this is String.valueOf() which you conveniently cannot call from a visualForce page in any way that I can find.