Unable to connect to database- Command: SELECT Format( AVG(candidate_result ) , 2 ) AS result, poll_post_date
FROM chart_info
WHERE poll_geo = 'US'
AND candidate_last_name = 'Obama'
AND poll_type = '2012 Presidential Election'
AND poll_id IN ( ,34,136,137,144,170,175,227,240,243,274,292,334,345,349,358,367,375,385,392,393,406,422,426,433,439,442,448,459,460,464,479,487,496,506,507,522,548,560,569,576,577,581,588,594,608,611,624,631,632,633,644,655,658,659,661,662,663,664,668,677,678,679,681,682,683,685,686,690,692,694,696,698,699,706,711,714,717,720,721,723,724,725,727,737,740,742,747,748,749,766,769,771,773,777,778,781,782,783,786,787,788,789,796,798,811,812,816,821,823,825,827,828,830,832,834,835,836,843,844,847,848,849,851,855,856,861,862,866,869,871,875,882,883,886,919,926,928,930,931,938,941,946,951,959,962,963,967,969,970,971,973,974,978,979,980,983,984,985,986,991,997,999,1016,1022,1029,1030,1031,1032,1033,1034,1036,1037,1040,1048,1051,1062,1064,1069,1070,1072,1074,1076,1080,1081,1084,1088,1091,1092,1094,1095,1103,1105,1107,1109,1118,1123,1125,1128,1133,1134,1135,1136,1137,1141,1142,1148,1150,1152,1153,1157,1159,1162,1165,1167,1168,1170,1171,1172,1173,1174,1176,1179,1182,1184,1188,1192,1196,1200,1204,1207,1209,1211,1213,1214,1218,1219,1220,1221,1222,1224,1231,1238,1241,1252,1253,1262,1263,1265,1266,1267,1268,1269,1270,1273,1274,1277,1278,1280,1281,1282,1283,1286,1292,1293,1295,1298,1299,1300,1301,1303,1304,1306,1308,1309,1310,1311,1312,1313,1318,1322,1326,1336,1339,1348,1351,1354,1357,1358,1360,1361,1362,1364,1365,1366,1376,1377,1380,1387,1389,1391,1392,1394,1399,1404,1408,1410,1416,1419,1420,1421,1426,1427,1429,1431,1433,1439,1440,1445,1451,1453,1462,1466,1468,1470,1474,1482,1484,1486,1489,1491,1494,1510,1511,1517,1522,1523,1526,1527,1530,1531,1533,1537,1538,1540,1541,1547,1551,1553,1564,1566,1568,1577,1579,1580,1581,1583,1585,1588,1589,1590,1597,1598,1599,1604,1605,1613,1619,1624,1627,1629,1643,1646,1652,1655,1656,1657,1658,1659,1664,1666,1667,1671,1673,1674,1677,1682,1685,1691,1707,1710,1715,1718,1722,1724,1729,1730,1735,1736,1739,1740,1744,1745,1746,1749,1754,1757,1758,1759,1763,1765,1769,1777,1780,1784,1785,1786,1787,1788,1789,1790,1791,1792,1797,1800,1806,1807,1811,1813,1821,1822,1824,1828,1829,1830,1831,1832,1834,1837,1839,1840,1841,1842,1843,1844,1853,1854,1856,1857,1861,1862,1863,1870,1887,1889,1893,1894,1898,1911,1912,1913,1917,1918,1936,1938,1944,1953,1955,1958,1961,1965,1970,1971,1980,1982,1987,1991,1996,2001,2008,2015,2018,2031,2042,2054,2058,2068,2069,2070,2079,2080,2086,2088,2089,2096,2103,2113,2121,2129,2135,2143,2155,2164,2165,2176,2186,2205,2216,2225,2235,2238,2243,2245,2249,2250,2256,2261,2262,2267,2269,2274,2281,2282,2290,2295,2298,2299,2309,2310,2320,2322,2327,2345,2354,2366,2368,2372,2377,2381,2384,2389,2395,2397,2398,2408,2410,2421,2430,2431,2433,2440,2442,2451,2458,2464,2472,2498,2499,2511,2513,2515,2526,2543,2545,2550,2551,2552,2557,2559,2560,2567,2568,2572,2576,2580,2586,2591,2602,2603,2612,2615,2627,2630,2632,2649,2660,2663,2664,2683,2684,2685,2690,2692,2694,2709,2713,2717,2718,2719,2723,2724,2730,2733,2734,2740,2741,2749,2751,2754,2762,2763,2765,2768,2776,2783,2787,2788,2793,2797,2800,2802,2809,2817,2819,2820,2825,2827,2831,2836,2837,2842,2850,2855,2860,2869,2870,2876,2887,2891,2895,2903,2904,2913,2915,2926,2928,2929,2932,2933,2947,2948,2949,2955,2966,2969,2970,2979,2980,2982,2992,2993,3004,3006,3031,3046,3048,3054,3067,3077,3079,3086,3089,3097,3107,3122,3132,3139,3160,3161,3170,3171,3175,3176,3192,3193,3197,3206,3219,3224,3231,3248,3249,3253,3255,3259,3265,3266,3267, 0 )
GROUP BY poll_post_date
ORDER BY poll_post_date ASC MySQL Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '34,136,137,144,170,175,227,240,243,274,292,334,345,349,358,367,375,385,392,393,4' at line 6