Unknown column 'spb_sort_top5' in 'order clause'
SELECT SQL_CALC_FOUND_ROWS p.*, pro_rating FROM SC_products p WHERE ( (p.productID IN (741,742,892,984,992,993,1069,1262,2015,2019,2020,2101,2102,2103,2104,2147,2226,2230,2237,2238,2239,2240,2242,2271,2272,2273,2274,2396,2424,2433,2484,2486,2553,2555,2556,2588,2589,2663,2681,2758,2762,2760,2763,2764,2765,2766,2767)) OR (categoryID IN (714)) ) AND ( enabled=1 AND (p.Price > 15000 OR p.categoryID IN (651, 652, 653)) AND spb_enabled=1 AND spb_enabled=1 AND `p`.`productID` NOT IN (1271,2193,2194,2200,2196,2228,828,728,729,730,731,1031,2001,2190,2191,2192,2214,759,760,761,762,763,764,765,766,767,2363,2360,2361,2364,2365,2366,2367,2369,673,674,675,676,677,678,679,687,688,686,2370,2372,2371,2373,672,864,865,867,868,869,870,871,2352,2353,2354,2355,2356,2357,2358,2359,1269,1270,2125,2116,2128,2129,2220,2221,2700,2152,2158,2157,2153,2154,2155,2156,2159) AND `p`.`productID` IN (667, 668, 669, 670, 671, 672, 673, 674, 675, 676, 677, 678, 679, 686, 687, 688, 692, 693, 694, 695, 696, 697, 698, 699, 700, 701, 703, 704, 705, 706, 707, 708, 709, 711, 712, 713, 714, 715, 716, 717, 718, 719, 720, 721, 722, 723, 724, 725, 726, 727, 728, 729, 730, 731, 732, 733, 734, 735, 736, 737, 738, 739, 740, 741, 742, 746, 747, 748, 749, 750, 751, 752, 759, 760, 761, 762, 763, 764, 765, 766, 767, 768, 769, 770, 771, 772, 773, 774, 775, 776, 777, 778, 779, 780, 781, 782, 783, 784, 785, 786, 787, 788, 789, 790, 791, 792, 793, 796, 797, 798, 799, 800, 801, 802, 803, 804, 805, 806, 807, 808, 809, 810, 811, 812, 813, 814, 815, 816, 817, 818, 819, 820, 821, 822, 823, 824, 825, 826, 827, 828, 829, 838, 839, 840, 841, 842, 843, 844, 845, 846, 847, 848, 849, 850, 851, 852, 853, 854, 855, 856, 857, 858, 859, 860, 861, 864, 865, 867, 868, 869, 870, 871, 872, 873, 875, 876, 877, 878, 880, 881, 882, 883, 884, 887, 888, 889, 890, 892, 893, 894, 895, 898, 903, 904, 905, 906, 907, 908, 914, 915, 916, 917, 918, 919, 920, 921, 922, 923, 924, 925, 926, 927, 928, 929, 930, 931, 932, 933, 934, 935, 936, 937, 938, 939, 940, 941, 942, 943, 945, 946, 947, 948, 949, 950, 951, 952, 953, 954, 955, 956, 957, 958, 960, 961, 963, 964, 965, 966, 967, 968, 969, 970, 971, 972, 973, 974, 975, 976, 977, 980, 981, 982, 983, 984, 985, 986, 987, 988, 990, 991, 992, 993, 994, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011, 1012, 1013, 1014, 1015, 1016, 1017, 1018, 1019, 1022, 1024, 1026, 1027, 1028, 1029, 1030, 1031, 1032, 1033, 1034, 1035, 1036, 1037, 1038, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 1047, 1048, 1049, 1050, 1051, 1052, 1053, 1054, 1055, 1056, 1057, 1058, 1059, 1060, 1061, 1062, 1063, 1064, 1065, 1066, 1067, 1068, 1069, 1070, 1071, 1072, 1073, 1074, 1075, 1076, 1077, 1078, 1079, 1080, 1081, 1082, 1083, 1084, 1087, 1088, 1090, 1091, 1093, 1094, 1095, 1096, 1097, 1098, 1099, 1100, 1101, 1102, 1103, 1104, 1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113, 1114, 1115, 1116, 1117, 1118, 1119, 1120, 1121, 1122, 1123, 1124, 1125, 1126, 1127, 1128, 1129, 1130, 1131, 1132, 1133, 1134, 1135, 1136, 1137, 1138, 1139, 1140, 1141, 1142, 1143, 1144, 1145, 1146, 1147, 1148, 1149, 1150, 1151, 1152, 1153, 1154, 1155, 1156, 1157, 1158, 1159, 1160, 1161, 1162, 1163, 1164, 1165, 1166, 1167, 1168, 1169, 1170, 1171, 1172, 1173, 1174, 1175, 1176, 1177, 1178, 1179, 1180, 1181, 1182, 1183, 1184, 1185, 1186, 1187, 1188, 1189, 1190, 1191, 1192, 1193, 1194, 1195, 1196, 1197, 1198, 1199, 1200, 1201, 1202, 1203, 1204, 1205, 1206, 1207, 1208, 1209, 1210, 1211, 1212, 1213, 1214, 1215, 1216, 1217, 1218, 1219, 1220, 1221, 1222, 1223, 1224, 1225, 1226, 1227, 1228, 1229, 1230, 1231, 1232, 1233, 1234, 1235, 1237, 1238, 1240, 1242, 1243, 1245, 1246, 1247, 1248, 1249, 1250, 1251, 1252, 1253, 1254, 1258, 1259, 1260, 1261, 1262, 1269, 1270, 1271, 1272, 1273, 1274, 1275, 1276, 1277, 1279, 1280, 1281, 1283, 1286, 1287, 1288, 1289, 1290, 1291, 1293, 1296, 1297, 1298, 1299, 1300, 1301, 1302, 1303, 1304, 1305, 1306, 1307, 1308, 1309, 1310, 1312, 1313, 1314, 1315, 1316, 1317, 1318, 1319, 1320, 1322, 1323, 1324, 1325, 1326, 1329, 1330, 1331, 1333, 1334, 1335, 1336, 1338, 1339, 1340, 2000, 2001, 2002, 2003, 2004, 2006, 2008, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2025, 2026, 2027, 2028, 2029, 2030, 2031, 2034, 2035, 2037, 2038, 2039, 2047, 2048, 2049, 2050, 2051, 2060, 2061, 2065, 2070, 2071, 2074, 2075, 2076, 2077, 2080, 2081, 2087, 2088, 2089, 2090, 2091, 2092, 2093, 2094, 2095, 2096, 2098, 2099, 2101, 2102, 2103, 2104, 2106, 2107, 2108, 2110, 2114, 2115, 2116, 2118, 2119, 2120, 2121, 2122, 2125, 2126, 2127, 2128, 2129, 2130, 2136, 2137, 2138, 2139, 2140, 2141, 2142, 2143, 2144, 2145, 2146, 2147, 2149, 2150, 2152, 2153, 2154, 2155, 2156, 2157, 2158, 2159, 2169, 2171, 2172, 2173, 2174, 2176, 2177, 2179, 2180, 2181, 2182, 2183, 2186, 2187, 2188, 2189, 2190, 2191, 2192, 2193, 2194, 2195, 2196, 2197, 2198, 2200, 2201, 2208, 2212, 2214, 2220, 2221, 2222, 2226, 2227, 2228, 2229, 2230, 2231, 2232, 2233, 2234, 2235, 2236, 2237, 2238, 2239, 2240, 2241, 2242, 2244, 2252, 2253, 2261, 2262, 2263, 2264, 2269, 2270, 2271, 2272, 2273, 2274, 2275, 2276, 2277, 2278, 2279, 2280, 2281, 2282, 2283, 2285, 2286, 2287, 2288, 2289, 2290, 2291, 2293, 2294, 2295, 2296, 2297, 2298, 2299, 2300, 2301, 2302, 2307, 2308, 2309, 2310, 2312, 2313, 2316, 2320, 2321, 2322, 2323, 2324, 2325, 2326, 2329, 2330, 2331, 2332, 2333, 2334, 2335, 2338, 2339, 2340, 2341, 2344, 2346, 2347, 2348, 2349, 2350, 2351, 2352, 2353, 2354, 2355, 2356, 2357, 2358, 2359, 2360, 2361, 2362, 2363, 2364, 2365, 2366, 2367, 2369, 2370, 2371, 2372, 2373, 2374, 2375, 2376, 2377, 2378, 2379, 2380, 2386, 2387, 2388, 2389, 2390, 2392, 2394, 2395, 2396, 2398, 2399, 2400, 2401, 2402, 2403, 2404, 2405, 2406, 2408, 2409, 2410, 2411, 2412, 2413, 2414, 2415, 2416, 2417, 2418, 2419, 2421, 2422, 2423, 2424, 2426, 2427, 2428, 2429, 2430, 2431, 2432, 2433, 2434, 2435, 2436, 2437, 2438, 2439, 2440, 2441, 2442, 2443, 2444, 2445, 2446, 2447, 2448, 2449, 2450, 2451, 2452, 2453, 2454, 2455, 2456, 2458, 2459, 2462, 2463, 2464, 2465, 2466, 2467, 2468, 2469, 2470, 2471, 2472, 2473, 2474, 2475, 2476, 2478, 2480, 2481, 2484, 2485, 2486, 2487, 2488, 2489, 2490, 2491, 2493, 2494, 2495, 2496, 2497, 2498, 2499, 2500, 2501, 2502, 2503, 2504, 2506, 2513, 2514, 2516, 2522, 2523, 2524, 2525, 2526, 2527, 2529, 2534, 2535, 2536, 2537, 2540, 2546, 2547, 2548, 2549, 2551, 2552, 2553, 2554, 2555, 2556, 2557, 2558, 2559, 2560, 2561, 2562, 2563, 2564, 2565, 2566, 2569, 2570, 2571, 2572, 2573, 2574, 2575, 2576, 2577, 2578, 2579, 2580, 2581, 2582, 2583, 2584, 2585, 2586, 2587, 2588, 2589, 2590, 2591, 2593, 2594, 2595, 2596, 2601, 2603, 2605, 2606, 2609, 2610, 2611, 2612, 2613, 2614, 2615, 2616, 2617, 2618, 2619, 2620, 2621, 2623, 2624, 2625, 2626, 2627, 2628, 2629, 2630, 2632, 2633, 2634, 2635, 2636, 2637, 2638, 2640, 2641, 2642, 2643, 2644, 2645, 2646, 2647, 2648, 2649, 2650, 2651, 2653, 2654, 2655, 2656, 2657, 2658, 2659, 2660, 2661, 2662, 2663, 2664, 2665, 2669, 2670, 2674, 2675, 2677, 2678, 2679, 2680, 2681, 2682, 2683, 2685, 2686, 2690, 2692, 2693, 2694, 2695, 2699, 2700, 2701, 2702, 2703, 2704, 2705, 2706, 2707, 2708, 2709, 2710, 2711, 2712, 2713, 2714, 2715, 2716, 2717, 2718, 2719, 2720, 2721, 2722, 2723, 2724, 2725, 2726, 2727, 2728, 2729, 2732, 2733, 2734, 2735, 2736, 2737, 2739, 2740, 2741, 2752, 2753, 2758, 2760, 2762, 2763, 2764, 2765, 2766, 2767, 2769, 2770, 2771, 2773, 2774, 2775, 2776, 2777, 2778, 2779, 2780, 2781, 2782, 2783, 2784, 2785, 2786, 2787, 2788, 2789, 2790, 2791, 2794, 2795, 2797, 2798, 2799, 2800, 2801, 2802, 2803, 2804, 2805, 2806, 2807, 2808) ) ORDER BY ( IFNULL(spb_sort_top5,0) * IFNULL(spb_prioretyw,0) ) DESC, Price LIMIT 10,12