this

MySQL returned error




Error Description :
Error No : 1064
Description : 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 ' is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,act' at line 1

SQL Query
SELECT COUNT(`book`.id) AS CNT FROM `book` WHERE id!=0 AND book.id<>0 and book.active='yes' and city_id!='' and book.id in(0,3415,5623,1727,1647,3850,3500,2380,1313,319,808,772,986,6564,3136,2151,463,6562,3585,1727,1237,4021,1098,1277,3610,5552,732,955,6644,6677,6599,1856,3454,447,780,1915,1160,5170,1460,2760,2707,2912,2270,2271,219,6779,1441,6709,2469,3351,1159,3482,3417,243,341,360,2685,652,2653,2654,2671,2454,3304,3447,1834,2602,3341,6827,2639,3844,943,2518,2298,5657,1871,3657,1869,231,2592,2477,2919,3843,5509,2974,2299,1822,1829,1297,3714,2334,4217,3787,3778,3760,5735,2456,231,2477,4796,4806,4808,3159,6828,5331,3035,6192,396,5692,2873,3437,975,6992,3447,4798,3825,699,944,2446,2387,1416,4855,1893,2864,4722,3788,2934,1228,922,2723,7003,836,4008,6852,1561,6901,6998,5247,925,5743,6663,675,1038,255,1521,5078,5142,2698,5631,6902,1131,6117,5764,2337,455,2160,3625,6188,462,7016,7224,7221,7234,7047,7237,7230,6364,501,470,1098,6572,4510,744,6562,467,1474,2571,4796,1568,2331,2033,423,5454,2457,6574,6571,6576,4126,4019,5089,5112,261,5623,1487,6644,6767,322,466,6766,511,360,215,1160,1441,5143,2912,3590,6539,6544,444,652,955,1561,1834,6040,6542,1371,1070,6660,2876,5719,6030,3302,1439,470,4008,6564,6565,6572,6575,1461,1593,6562,3797,4165,1092,744,6568,3645,7063,6998,467,7119,7095,4164,1600,6521,4423,7089,7093,4964,6527,1474,7121,6522,1098,6504,6735,7115,6576,7115,6902,7125,7029,6503,6901,7047,6523,6996,7223,7235,7001,7029,1460,2456,7233,6675,3418,7013,652,2917,2696,7112,2956,1425,7249,7276,341,3447,943,1869,7231,3760,2446,3454,7234,2456,2454,3610,1893,1765,944,7034,2151,1829,7089,2974,6588,7272,7271,6168,7272,6350,7271,7273,3417,7296,2334,6530,2671,7280,2653,5371,6365,7241,6676,7258,6993,2876,7057,7106,397,4021,6678,6726,6518,6512,6371,726,6528,6530,6529,6531,7691,7689,4305,860,7692,650,7686,7699,7681,4224,6530,313,810,7753,272,7275,5066,7844,3784,7661,7670,7602,7662,7108,7084,7265,7268,7170,7168,7599,1771,1767,1207,1769,1765,1768,6669,2299,2639,3415,5765,1869,1893,6994,3788,4164,231,836,2454,2864,3181,3778,3760,6993,3454,6575,1350,3370,975,1181,4160,2192,4423,396,3797,1738,455,734,1131,6192,744,5877,5362,766,4972,2674,5179,5764,4696,4861,2632,5247,1038,5764,2381,4730,1152,2882,4766,1057,1890,1439,1532,5543,2192,2331,2360,4240,3761,1042,4830,1835,1176,2657,5321,1177,7156,1826,1190,3062,3775,1461,6848,6780,1600,5321,2876,467,1176,7761,5487,470,3059,1092,3590,3303,1098,4964,3844,5765,7019,1600,1416,4947,2261,1460,2760,3136,4164,5218,3493,4984,3830,4348,6981,6104,5995,7834,1522,1869,2639,7837,7995,7836,8150,8146,8135,8000,7354,8087,665,7919,1416,1038,3303,5764,3590,3989,5623,8183,2033,215,5179,3844,6824,219,243,261,360,3067,3303,3341,3415,341,3418,3482,3778,8150,3788,4217,4722,5306,5509,6827,7835,6632,8089,4652,3941,5362,1257,1253,1318,1432,1325,8306,6154,3368,446,3830,4337,6713,1349,5576,1521,6595,1532,4652,3761,4460,1461,1038,1690,6684,5545,5719,7708,1369,7920,4395,4131,7812,7138,7239,3542,7839,3941,4082,7783,4209,6117,4566,6793,7919,4258,4796,7020,8305,4983,7836,8222,308,5997,7821,7760,1347,5657,7803,8025,6849,8020,7835,6780,6156,7212,7147,6813,8923,8869,8890,4131,8925,8901,8900,8846,7839,4209,9054,8055,8080,7110,8044,665,7582,1253,6154,6315,6639,585,606,736,6674,8911,6942,6694,7712,1690,2025,2135,7602,8089,8306,6782,7138,3904,6863,4355,4220,8019,8615,8222,1461,9195,2590,7106,7096,223,5020,2933,6010,4023,7857,734,6785,6673,8025,7138,7005,7859,5286,228,3933,6792,4801,5148,5373,5349,5339,6901,8543,7837,7835,7834,7836,8441,9376,9073,9528,779,810,578,730,4639,4405,6809,6845,6104,6805,2615,4659,1603,5484,5904,7146,6979,4774,5116,7303,1764,1460,6687,3492,5276,7144,3797,4854,4316,4964,423,5298,5003,7756,1272,510,4985,6953,1831,7882,7874,4512,2989,5400,470,5763,3358,6559,7981,7988,952,1092,3856,665,2331,7994,2913,3719,7956,3893,8135,5889,3878,4087,7287,4652,1184,3136,5995,7807,5332,7937,6732,7971,549,5965,4616,3824,8483,8484,6560,3169,5252,8257,4784,4830,8514,8573,8169,1872,8471,2024,6192,1349,7985,8305,2989,7251,3580,6255,6829,8713,3169,435,3134,1718,734,228,1207,3645,6986,1600,1593,744,2331,6731,1000,223,1318,4855,4199,2571,5735,1460,6643,2671,7029,7020,7047,4164,6902,4165,341,6998,1577,2469,2685,6827,3584,4219,5770,2706,3954,6966,1593,3913,1245,2778,6804,3926,1770,1771,1085,1771,1070,1769,1767,5148,1561,6964,6110,1768,4426,6966,6961,4164,6471,4165,6504,511,510,2469,3216,1370,6383,6415,470,467,2605,3702,858,4788,1741,3771,2035,5821,344,1165,663,979,3989,1770,1765,2706,3830,3370,4943,6371,4423,6354,1600,744,1381,455,3761,2331,1232,2183,3610,3172,1474,3172,2615,3131,1185,1738,3217,7752,567,7748,663,7964,4218,5576,7779,2869,8000,1351,834,3541,2334,344,6660,3250,5091,4701,2671,7604,2653,3136,3417,6413,4972,7033,7896,6940,3645,1098,1593,1407,4964,4984,1561,1460,3797,4008,4830,5218,8095,1070,5091,1738,8150,3803,6809,548,1741,6845,6223,546,6042,6496,5763,540,3094,7616,1917,7751,2729,3878,5228,5246,5328,4103,6397,3872,2451,6218,543,1764,7987,7903,7972,7973,2677,1145,8117,8140,7833,1126,5143,2776,28,1398,923,1234,3189,4872,5089,5094,1520,8222,7861,5112,1207,956,3392,6901,2915,6902,7047,6902,3048,537,539,8306,7986,6124,4144,7208,4785,5459,5430,28,947,7776,906,466,1370,1741,7029,7047,7047,1318,423,1092,8252,532,1600,8888,4855,4855,9017,545,7047,8542,5914,6034,7829,7029,7029,9021,7592,3878,7681,7681,6552,9554,9547,9547,9007,9007,9614,9777,9254,7710,9675,9880,6222,6499,6214,6220,6218,6215,6501,6216,6498,6497,6223,6212,9965,9254,10265,532,9648,10258,10212,10212,57,28,9487,10610,10610,11089,10622,11089,10622,1126,1145,2331,4432,5996,8019,5251,3368,947,8220,5956,3875,4178,6768,6388,1704,8547,6218,6223,6521,744,1600,467,423,470,9770,9566,5312,8000,4830,4984,5218,4423,3136,4008,1474,1593,8894,9378,1460,1098,4164,4165,89,2760,4395,3370,1234,435,9533,9418,5306,3067,2904,1407,3541,4944,1662,8389,10102,10110,1593,6740,10098,10107,8305,6212,10269,7869,2164,4788,9675,1425,5218,2776,9676,10054,1561,2904,7033,10442,89,661,1092,1318,1407,2904,3094,4165,8241,4301,10913,10983,10999,11008,4160,11009,11006,11021,11020,10142,467,744,1407,3541,4964,5312,8000,1098,4830,4348,1318,1593,3645,3797,5218,5170,89,4008,4164,1561,28,9655,4348,1474,744,9418,11409,10278,11402,1092,11228,4165,470,11252,1092,4984,1198,4940,9378,4943,11546,8995,9838,11610,2824,2785,2778,6443,5306,2904,6962,661,5306,2904,7751,11663,11657,1237,11546,566,4165,3645,2760,1600,467,11485,956,57,9533,10278,11228,11812,3370,3136,7222,9270,10086,10094,10056,5170,3904,6354,3073,2698,3070,10134,9603,9475,2271,986,3351,3429,5631,10132,10133,2707,1159,4901,5837,10210,10018,780,743,772,4406,10277,5131,4653,10285,10286,802,1441,1160,1110,10205,3825,10287,7758,7858,6852,7865,9353,7864,1915,2654,1277,9607,732,10207,10241,10242,10104,7856,7855,7221,3731,10130,10209,10148,10344,10345,2912,10374,8946,10376,8919,10358,6902,141,10243,10373,6163,10065,9406,9511,3731,8910,8095,10416,10543,10400,9910,8813,10399,8812,9252,10401,10479,6901,9929,10120,9937,10362,10476,10530,9769,10046,10660,10661,10662,10112,9386,10633,9748,10119,10118,9761,4240,802,5321,2657,10709,10708,8687,10710,9253,9251,1835,1190,1177,9466,8387,1176,7554,7754,7755,7756,7927,8509,10528,10062,9770,9222,9253,9251,10787,10857,10523,10395,10836,10814,10870,10396,10358,10569,9614,10632,10244,10634,10917,10918,10568,10635,10584,10583,10636,7029,10919,2912,7674,141,3351,7856,9512,9531,9532,2658,9551,9566,9569,9570,4199,9568,11028,8615,9528,4624,4730,8902,446,10212,10895,8888,8278,8276,8275,10657,10913,10911,9981,8799,9987,10141,7221,10205,10207,9277,3428,7239,10066,10165,10236,9402,8031,1253,5545,10413,4969,9454,11027,10414,7636,8095,608,1368,10549,10837,848,10512,7580,4766,9391,9982,4233,9571,8252,3100,10649,11112,6163,11141,8842,5013,5154,10113,10114,8629,8837,3029,228,10063,11142,9904,10967,11102,9543,217,10087,11219,11126,10938,11217,4337,6863,11202,11122,11220,11100,11084,11123,28,11106,11268,9638,7550,10397,11180,4984,1917,9950,11219,10784,661,10127,744,6731,57,467,1092,89,4785,4536,2873,11374,2871,6730,4329,6692,4882,6776,3100,2317,6185,11330,5131,4406,11228,4046,4048,4045,10377,8147,7057,7857,7003,6736,4049,4050,6741,2033,8517,6705,4136,7016,9251,8812,8813,9252,9464,11302,11235,2639) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC