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,8222,7579,7837,4079,1210,7834,4639,7835,7836,6740,7143,4087,8358,7238,223,8220,8517,3282,7989,8306,8547,8480,2117,8610,435,8610,3014,8629,8214,5143,4218,7923,3850,8842,1207,8905,8912,6599,1127,8916,9000,665,1345,8578,8780,9046,9130,9195,9017,1461,9072,3062,4625,8933,8706,5154,9200,9242,984,9254,7907,5536,9300,3761,8495,9322,9332,9333,9334,5732,9308,9289,9291,8103,9337,1057,179,8150,3595,2135,9456,3059,9419,9290,8688,7803,9196,9347,9541,8543,8306,9552,8306,9353,8306,7581,8306,6117,9607,9603,9604,7143,6857,1890,9641,9634,9654,9643,9668,9642,9644,2360,9377,4240,9680,107,9616,9761,9234,8805,9648,4219,9676,9769,9766,9780,9800,7856,772,9798,3844,4800,3303,2299,9116,2294,5515,5765,3590,2398,9258,1416,9913,9916,9938,9942,8913,9635,5841,780,9961,3844,9543,9945,129,9471,3159,3788,444,5692,1834,8870,8844,972,10047,6848,1727,1822,360,10056,734,7615,6681,5812,7016,2674,6827,1181,10128,10129,9086,3181,10141,10149,3437,10119,10120,8925,10048,10061,967,9472,1522,9963,1906,10093,220,4126,9116,5821,2743,1485,1000,152,10229,10242,10241,180,148,958,1461,2135,2192,3585,2299,10131,10282,10284,8884,4947,7019,10273,2687,2642,1826,3561,10283,9936,2421,4656,4566,4972,2571,10342,10338,10246,9348,115,10300,10380,10373,10209,10358,9050,4527,10374,10373,10440,5743,6171,10469,4168,10467,10476,10416,10479,9374,9638,10042,6267,9220,3608,5877,3035,4986,8851,9454,8837,10523,10114,10244,10527,10247,5551,8902,10394,8800,10549,10541,10537,10548,10543,322,10514,8514,1954,10021,4385,9193,1057,7550,6691,162,8901,10671,10649,9904,4767,4696,10665,7017,7582,10674,10569,5729,10745,1954,10747,10787,10798,4023,10780,10814,10737,10663,3715,10784,10836,10688,4082,10135,10782,6713,252,10878,10699,10870,5373,10935,10894,7016,10910,10892,10934,1350,4136,1521,10938,10918,10966,5142,10895,10893,10656,7140,10397,606,10782,8900,10988,5379,6828,2192,10233,7614,1532,9834,6643,10708,11028,10709,7064,10710,9081,10285,3054,7021,2270,2271,1131,10221,2672,10344,3825,10345,10513,11084,10320,123,11090,10661,10662,11105,10398,11104,7143,10990,11094,6838,239,10899,10778,9872,10673,11104,2642,7016,7710,9254,3391,9768,9254,9270,1277,7016,955,6861,1441,2654,1055,2707,1160,1159,30,243,11121,10376,10917,1160,30,11123,11127,11128,5631,11132,8687,11126,10765,11089,10454,5875,743,7758,10094,11135,11142,11136,10964,6849,2912,4982,10857,2698,10971,10733,9453,6852,10343,7864,780,3964,8835,3657,2639,3542,5379,4219,7855,1277,1042,8919,11166,3775,10148,10375,3778,5678,4665,9928,10130,5305,11180,10719,1835,11195,10473,6696,3787,6853,4362,9105,1176,2671,1313,6661,4616,2919,11219,11222,11217,10734,11230,11201,3100,10819,11237,10657,2709,10434,4233,1119,11220,8535,11199,9234,11200,4209,5487,9096,3457,2446,10861,8031,5545,6731,11198,11235,10528,6731,11084,9722,11288,11287,11268,1209,11304,11302,11272,4056,6862,6779,11324,11325,8134,9343,5046,36,1698,2590,748,5903,11349,3936,11041,11353,3376,3195,3139,4028,4648,8802,11361,2592,2919,2685,11359,11360,2873,4536,11389,11351,11374,3482,2655,7036,3396,9402,6866,11409,10940,11417,11266,11424,11423,10715,5013,11314,11266,9811,10062,10146,24,4875,10714,11142,5252,11443,8010,10530,10714,11442,6730,9922,11438,1049,11433,1050,9221,739,11473,11437,10288,10234,11480,11456,11450,11388,11491,11494,4329,11455,9615,11488,6692,11381,11498,11489,11347,11344,11468,768,1576,11476,11371,11477,11382,9750,4648,11102,4882,11416,2555,986,9809,9807,9808,141,986,11290,3368,11492,152,10842,2477,7709,8224,3523,11599,11042,10912,11595,11598,11613,3041,2456,122,3500,3540,5328,11621,1299,6693,11373,11597,11593,11619,11518,11600,11606,11655,11620,11648,11436,10368,11661,11647,11670,11435,11451,4233,11479,11646,11678,11594,11303,11446,61,11523,4432,11663,11691,11644,10002,11362,1113,11690,10685,11698,11703,779,9965,11719,11672,11669,11724,11680,11714,11126,11446,11702,11705,11738,11737,11725,6986,3401,925,8707,8520,9222,4061,11385,2491,7760,8104,9317,5047,11658,4099,11170,9068,8483,9070,6337,4849,11764,11765,11673,9532,9987,7896,8146,2454,11379,2419,1298,9531,258,11657,5553,6902,258,11770,11772,3714,218,11752,10635,9018,11786,11660,11807,11812,9511,7362,11816,6901,11787,11785,11282,9036,10967,5629,11330,11659,9986,11681,11716,9228,11285,11827,11819,10764,4696,11821,11820,11842,11845,11829,11010,11846,11826,11869,11831,11872,11662,10956,11851,9917,11822,11699,11847,9964,9967,10877,8284,11832,11871,5885,11870,11849,11873,11900,10743,2921,9211,9166,9642,9643,9644,11921,11828,9641,10066,10012,10015,6310,10019,6104,504,6103,7239,6364,3728,1232,7019,6981,3531,7374,5914,1145,7878,7143,7840,7761,7872,7903,7937,4535,7910,7938,3549,867,7358,2389,3419,2182,7770,7771,8169,511,7911,8222,7108,8231,2467,3029,8288,512,7637,8358,5995,4983,7085,4765,4985,8469,7271,7828,3115,3559,8174,2117,8547,8626,507,7928,8705,8704,8706,2473,8706,8480,8304,8706,7125,7775,7077,3725,8683,8087,8818,7751,7972,7973,4406,8213,2989,8908,8909,2989,8776,8836,8910,8947,6821,8816,9029,9009,7599,8943,9009,8944,7595,7881,4969,2029,4983,3169,8141,3532,9198,6138,9202,1230,6138,8812,7589,4701,9216,9278,1770,9307,9331,9330,9349,9334,7998,7999,9277,9422,9479,9546,9212,9558,9612,9613,9646,9649,9383,4985,9727,1768,9736,1766,9770,1890,931,9767,9759,9386,8543,2294,223,9799,9887,9871,4405,7265,8419,9978,9884,9979,10001,10001,10053,10072,10001,4784,10111,9378,9989,8211,10073,10108,10073,10121,8780,10121,10225,10237,10247,7139,9148,9377,10219,8554,10163,10124,10261,9900,9093,10123,7675,9116,9834,10293,10273,409,9257,10492,9423,10531,7777,10543,7766,10543,8914,10543,10209,10129,10127,10467,9136,10818,10724,10976,10649,8842,7634,10412,7149,3043,4512,2520,8305,6642,3728,6780,5484,4936,6138,452,222,1181,8933,6364,8995,9104,8960,4944,8962,665,2998,8999,8182,4901,8306,1245,8141,7852,8613,8910,455,1912,9208,8970,8231,1738,2974,2151,7920,1055,1727,6855,9389,5623,2299,2639,955,5765,9223,9222,8844,9224,9255,9250,9402,3303,8965,9623,8960,4969,4128,254,5516,4656,9011,9290,9556,8812,8151,4049,9275,9344,4046,6986,9397,9766,4061,9777,9464,9951,9959,9827,8554,9910,9931,1016,10012,5236,10040,10014,3908,5046,10017,10015,10019,10004,10109,10110,9243,9981,9250,8762,10056,10090,7759,4099,3936,6766,9758,6571,10013,8889,10086,10242,8031,10018,9482,9541,162,4566,6876,9538,9652,10021,9926,3590,10039,8844,8870,1568,10361,10397,10055,10241,2639,3415,10267,10355,10358,5839,10547,4056,9402,10480,9243,10619,10620,10621,5039,9273,8019,6681,8305,9647,10227,10711,10718,10063,2639,3844,1055,2299,3585,10720,10785,10350,10895,9558,10003,10619,10783,10784,5193,10734,10856,10380,10966,1485,10439,10440,8193,10805,10552,10820,7760,9749,10895,9968,10857,11028,9798,10149,10476,10715,10878,2954,9634,9929,10364,10131,10283,10284,7581,9648,9930,10648,10711,10990,11142,9961,10895,10964,11018,10135,11123,9347,6857,11220,2506,36,11234,11302,2446,129,9471,8543,6117,10476,11272,10935,11314,9961,11383,11382,10413,10786,228,11287,10748,10749,10397,11106,11395,11424,10870,5877,11304,10129,11302,11473,10934,11446,11423,3964,11396,10785,11171,11602,11608,11442,11443,9347,11599,9961,11457,10413,10608,8441,7835,10719,11353,8441,7835,11655,10819,10911,10672,11344,11646,4185,5542,5906,2889,254,5247,5322,3216,5837,6315,320,5331,6796,3026,464,6700,6866,5331,1462,508,6121,1230,924,4218,5994,922,6364,6382,5956,3542,6130,1645,7304,5996,5909,3037,4109,567,4834,1557,5088,6891,1325,4450,405,2117,1998,421,324,4029,7547,7143,4690,2729,4432,3054,5763,5735,4986,450,4320,4659,4722,2246,6809,7834,5904,1073,8093,7592,7837,7835,7836,1461,8103,8151,7907,6828,4765,3549,7910,7359,637,3014,501,6838,5602,1327,7919,8092,3872,4901,3904,358,435,4056,1119,1121,7861,1215,4983,1029,7812,7783,8617,4731,8629,8793,8745,6642,8555,8837,8836,8869,4566,8919,8840,7037,1461,4730,6397,4950,36,768,8169,9030,9075,9073,8933,9074,9072,9164,9163,8841,9096,9072,9074,9216,9244,9243,9242,7815,4395,8441,5088,5236,9281,7899,9344,2253,6310,5046,4061,6986,1038,4339,2847,8839,8031,8547,7559,9460,9456,9459,9464,9455,9454,7354,7587,6713,3261,6782,8089,2882,1516,504,9497,7833,9479,9546,9757,9647,9463,9814,9635,2989,7804,8970,9810,5881,5885,7548,7873,6842,8280,8291,8818,9038,9334,9078,9614,5915,7140,3395,9345,8978,10004,8504,9990,9637,9888,9897,9910,10113,9900,10114,6002,6981,9967,9603,10046,2446,9753,9788,409,9319,10039,9828,10064,9558,10060,10088,10182,10087,10261,9987,1385,10109,10260,10267,9354,10237,10358,9769,10258,10183,1142,9180,9185,9299,9506,9801,10063,10259,9389,10229,8910,9406,9275,10210,10528,10121,10547,10549,10297,10343,10364,10380,10320,10319,10318,10564,10699,9959,10090,10480,10187,9919,10820,10700,10471,10505,10741,10847,10569,7131,10655,10668,10712,10977,10967,10972,10893,10702,10935,10679,10538,10119,11044,11090,11041,10971,10416,10715,10719,11021,9336,11103,11104,11042,9615,10174,9969,10440,10780,10785,10737,11106,10754,10734,9617,10778,11028,10749,11129,11135,11162,11163,11134,11089,11237,10536,10842,11126,10876,11258,11230,10261,10875,10878,10865,10086,11282,11220,11272,11315,11339,3493,11372,11382,11361,11121,11397,11234,11127,11446,11450,11381,11131,11386,11271,10236,5795,10837,11487,11423,11213,11377,11359,10938,11621,11551,11606,11379,11612,11703,11698,11646,11724,11440,11230,10663,11593,9896,11800,11669,11678,11850,11872,11363,7144,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,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,645,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,3844) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC