Got new info that pinpoints it:
The following sql is executed against the database. It both fails on our converted database and the default database that OnTime install for you. So you shoul dbe able to reproduce the error with this sql.
>>>>>>>>>>>>>>>>> Snippet >>>>>>>>>>>>>>>>>>>
exec spS_Defects_WithNames @FilterByProjectSelection = 1,
@ProjectId = 3286,
@IncludeArchived = 0,
@IncludeInactiveProjects = 0,
@IncludeSubProjects = 1,
@where = N'(Defects.ProjectId in (0,2246,2248,2249,2250,2251,2252,2253,2254,2255,2256,2258,2259,2260,2261,2262,2263,2264,2265,2266,2267,2268,2270,2273,2274,2298,2299,2300,2301,2302,2303,2304,2305,2308,2313,2321,2323,2324,2326,2328,2356,2388,2389,2390,2391,2392,2393,2394,2395,2426,2427,2428,2430,2431,2432,2455,2456,2459,2460,2461,2462,2463,2464,2469,2470,2471,2475,2476,2477,2478,2479,2480,2481,2482,2483,2484,2485,2486,2487,2488,2489,2490,2491,2523,2525,2528,2530,2531,2532,2533,2534,2535,2537,2538,2539,2540,2541,2542,2543,2544,2545,2546,2548,2549,2550,2551,2553,2554,2556,2557,2558,2559,2562,2564,2565,2566,2568,2569,2570,2571,2573,2574,2575,2576,2577,2578,2579,2580,2581,2582,2583,2584,2585,2586,2587,2588,2589,2590,2591,2592,2593,2594,2595,2596,2597,2598,2599,2600,2601,2602,2603,2604,2605,2606,2607,2608,2610,2612,2615,2616,2617,2618,2619,2620,2622,2623,2624,2625,2626,2627,2628,2629,2630,2631,2632,2633,2634,2635,2636,2637,2638,2639,2640,2641,2642,2643,2644,2645,2646,2647,2648,2649,2650,2651,2652,2653,2654,2655,2656,2657,2658,2659,2660,2661,2662,2663,2664,2665,2667,2668,2669,2670,2671,2672,2673,2674,2675,2676,2677,2678,2679,2680,2681,2682,2683,2684,2688,2689,2690,2691,2693,2694,2695,2696,2697,2698,2699,2700,2701,2702,2703,2704,2705,2706,2707,2711,2712,2717,2718,2719,2720,2721,2724,2725,2727,2728,2731,2734,2741,2744,2745,2746,2747,2748,2749,2750,2751,2752,2753,2754,2756,2757,2758,2759,2760,2761,2764,2765,2767,2770,2771,2772,2773,2774,2775,2776,2777,2778,2779,2784,2785,2786,2787,2788,2789,2790,2791,2793,2794,2799,2801,2802,2803,2804,2805,2807,2808,2809,2813,2814,2815,2816,2817,2818,2819,2820,2821,2822,2823,2824,2825,2826,2827,2828,2829,2830,2831,2832,2833,2834,2835,2836,2837,2838,2839,2840,2841,2842,2843,2844,2845,2847,2849,2850,2851,2852,2853,2856,2857,2858,2859,2860,2861,2862,2863,2864,2867,2868,2869,2870,2871,2874,2875,2876,2877,2878,2879,2882,2884,2885,2886,2887,2888,2889,2890,2891,2892,2893,2894,2895,2896,2898,2899,2901,2903,2905,2906,2907,2908,2909,2910,2912,2913,2914,2916,2917,2921,2922,2923,2924,2925,2926,2927,2928,2929,2930,2931,2932,2933,2935,2936,2937,2938,2939,2940,2941,2942,2943,2944,2945,2946,2947,2948,2949,2950,2951,2952,2953,2954,2955,2956,2957,2958,2959,2960,2961,2962,2963,2964,2965,2966,2967,2968,2969,2970,2971,2972,2974,2975,2977,2978,2979,3002,3003,3004,3005,3006,3007,3008,3009,3010,3011,3012,3013,3014,3015,3016,3018,3019,3020,3021,3022,3023,3024,3025,3026,3027,3029,3030,3031,3033,3034,3035,3036,3037,3038,3039,3040,3041,3042,3043,3044,3045,3046,3047,3048,3049,3050,3051,3052,3053,3056,3057,3058,3059,3061,3062,3063,3064,3065,3066,3067,3068,3069,3070,3071,3072,3073,3074,3075,3076,3077,3078,3079,3080,3081,3103,3104,3105,3106,3107,3108,3109,3110,3111,3112,3113,3114,3115,3116,3117,3118,3119,3120,3121,3122,3123,3124,3125,3127,3128,3129,3130,3131,3132,3133,3134,3135,3136,3137,3138,3202,3203,3204,3205,3207,3208,3209,3210,3212,3213,3214,3215,3216,3217,3218,3219,3220,3221,3222,3223,3224,3225,3226,3227,3228,3229,3230,3231,3232,3235,3236,3237,3238,3239,3240,3241,3242,3243,3244,3245,3246,3247,3248,3249,3250,3251,3252,3253,3254,3255,3256,3258,3259,3260,3261,3262,3263,3264,3265,3266,3267,3268,3269,3270,3271,3272,3273,3274,3275,3276,3277,3278,3279,3280,3281,3282,3283,3284,3285,3286,3287,3288,3289,3290,3291,3292,3293,3294,3295,3296,3298,3299,3300,3302,3303,3304,3305,3306,3307,3308,3309,3310,3311,3312,3313,3314,3315,3316,3317,3319,3320,3321,3322,3323,3325,3326,3327,3328,3329,3330,3331,3332,3333,3334,3335,3336,3337,3338,3339,3340,3341,3342,3343,3344,3345,3346,3347,3349,3351,3352,3353,3354,3355,3356,3357,3358,3359,3360,3361,3362,3363,3364,3365,3366,3367,3368,3369,3370,3371,3372,3373,3374,3375,3376,3377,3378,3379,3380,3381,3382,3383,3385,3386,3387,3388,3389,3390,3392,3393,3394,3395,3396,3397,3398,3399,3400,3401,3402,3403,3404))',
@orderby = N'Defects.DefectId',
@page = 0,
@rowcount = 0
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Notice that if you shorten the @where line to something like this, no error is thrown.
@where = N'(Defects.ProjectId in (0,2246,3404))',