I must be missing something..
The date is always 1 day behind when formating like so:
datetime xDate = o.campaign_start_date__c; String xxDate = xDate.format('yyyy-dd-MM'); system.debug('sdate :' +xxDate);
I set the above field to 8/16/2011
and in debug it shows up as: 2011-15-08
Everytime I change it the debug value is shown as 1 day behind.. Im sure I could to +1, but could someone help me understand why this is happening?