November only has 30 days, 20131131 can't be converted to a date because it doesn't exist. Change the where clause in your first statement from
WHERE some_other_field BETWEEN '20130901' AND '20131131'
to this
WHERE some_other_field BETWEEN '20130901' AND '20131130'
It should execute no problem.