Normally the only time I get an error like this is when I "connect live" to the data and it is a fairly large database. Are you getting this same type of error after you create a Tableau data extract of your data?
If so, I'm guessing there is a limit to the number of conditions in an "if" type function - I would not know what that limit is however.
Converting it to an extract worked. Thanks for your help!