• Did you ever resolve this? I have a similar issue with VS2012 giving me warning messages about resolving sys.partitions from within a user defined function (UDF) definition. The actual code works if queried directly, and the UDF defined from the code works just fine, but the warning messages in VS2012 regarding the inability to resolve the reference to a system catalog piece in disconcerting.

    Thanks!