/* BeejBlog */

[SOLVED] SSRS (2012), Excel export, “Not a legal OleAut date” error

Wound up being related to executing TimeSerial(0,0,secs) when specified secs represented more than 24 hours. Somehow the Excel rendering pipeline was the only one out of the various export formats that was susceptible to this issue which is interesting. From the TimeSerial specs I don’t see anything inherently invalid about going that high… the docs indicate it simply rolls it into the day portion of the resulting value as I would expect. Given that the error refers to “Ole”, there is some other intermediate data type conversion going on here… perhaps it passes through a time only type???