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,9590,10563,10923,10140,10147,8308,10924,9435,9436,726,5864,6504,10594,10596,3066,10600,8885,7014,6381,10522,10922,8586,8682,9920,8618,7891,10612,6191,10996,10998,10193,10197,10195,10200,10597,10640,10641,11054,10645,10639,10838,10753,11139,10999,11011,11012,10993,9410,9411,9416,9429,9430,10139,10151,10153,10176,10637,10199,10642,11055,11138,9232,11049,10799,8875,9113,9114,9182,11157,11158,11159,11154,8662,11155,11057,11153,11156,10800,11008,9587,8325,8596,11152,10201,8324,10557,10556,10558,10559,10561,11161,10562,9589,9593,11242,11240,11046,10801,9588,10333,11238,11207,11151,11218,10727,11149,11241,9781,10646,11204,3784,7568,7569,7570,8330,8331,8336,8339,8341,9633,11209,11244,11245,10644,9087,10337,4804,6221,6497,6214,6220,6216,6501,6218,6215,6499,6212,2720,11203,11269,11205,9593,10323,11183,11178,11231,10326,10198,11184,9137,11301,11206,11176,10102,11009,8309,10096,10322,8872,8242,8327,9424,10334,9891,10218,8335,10214,8329,10920,10646,11320,11322,6538,6534,6532,6533,6536,6505,6506,11318,8883,1730,7169,10827,10828,10750,10829,9426,4714,11242,11167,11238,11295,10139,10752,810,1266,10725,10729,10522,11317,10557,9430,9592,9535,9894,10101,10102,10326,11405,11157,10556,11048,3896,3895,3893,3889,3885,3883,8272,6493,3897,3894,533,532,528,527,526,525,551,550,548,542,541,540,3892,3891,6042,553,539,531,524,3890,3888,3887,3884,11296,4510,6381,11430,7986,7987,537,8274,10137,11467,10321,8764,4558,8111,11432,3881,11407,10324,11022,6214,6223,10801,11247,10643,10647,8273,10466,8682,7546,11161,11405,4791,6223,11493,6518,6519,6535,6537,6372,6371,11294,6498,11254,6496,11139,10560,10201,6215,4555,9108,10822,11394,11584,11585,11586,11590,10216,10562,11574,11591,8335,8329,9412,9409,8332,9425,9427,9428,11617,11624,11625,9431,9432,11616,11615,11241,11589,11591,11601,11375,11650,11425,11575,11580,9905,11588,11592,11229,10921,11173,11174,6521,11429,553,551,550,542,541,540,539,537,533,532,531,528,527,526,524,545,543,538,535,529,554,549,547,9520,9521,9587,11321,11611,7546,11493,1768,1769,9880,1766,9920,11427,11697,8294,10321,3066,8294,6212,6501,6496,6214,6221,8883,6223,6222,6216,10216,11054,11156,11154,10639,11723,11618,11677,11759,8340,8334,6042,3883,6456,323,6453,6455,6454,6390,11650,6995,10371,10138,8331,8320,8327,11571,11030,11696,11031,11695,11032,11461,11460,11033,11406,10925,8273,11799,10520,8585,9149,4390,8154,11069,10257,10521,11078,11079,11080,11081,11077,11051,11791,6354,11576,7194,673,11075,10797,3070,3073,10053,10975,10544,11221,11587,10725,9259,10920,10923,10561,7119,9206,10214,10563,6270,9148,10216,8339,7933,9905,10194,10195,10922,10862,10333,10821,11137,11048,10921,11139,8729,10200,9587,5635,11146,10199,10925,10201,10328,11147,8897,11013,10558,10330,10329,4386,11015,10331,10098,11014,11016,10323,10443,11022,11154,11148,7186,7187,10215,10607,7176,7180,2799,11157,7179,7182,7181,7183,7185,9590,11156,7178,8596,10139,6654,10557,10560,7189,10800,9535,7184,11152,11153,6652,11051,7188,11240,11138,11247,8878,6653,8880,10335,11269,10551,8243,11167,11242,11033,10253,11241,10153,9970,10043,11031,9907,10256,8330,11296,11294,10728,10519,10799,9492,1245,10336,10970,5096,8248,11030,9410,10254,8327,10176,10218,11301,10100,8336,11022,6688,10803,6689,8946,3071,3073,6354,3070,6689,8088,7752,8627,9037,8727,10805,11221,6212,6215,4714,11238,11318,11317,11405,11406,10828,9880,10822,8343,11427,11431,374,11426,9903,11421,11422,6271,11419,9905,1250,11420,11418,5383,10804,3359,9679,10840,6689,9473,11464,11463,11252,11430,11466,11493,9806,11241,10726,10728,10555,8244,11042,2709,9416,8917,11082,11085,2743,3613,8260,11050,10522,6600,1762,1681,11050,8336,9792,10606,9231,5656,10970,10607,8319,3613,8874,7370,6485,5516,8599,11050,10324,8875,10799,11055,8598,11139,8699,9112,11009,10963,8193,11008,11137,11149,11048,11047,11151,2826,6442,11054,11157,2827,2825,11057,8242,11159,9409,11138,11161,6489,2815,2823,9184,9410,11158,2822,2821,2824,11156,11240,2816,2817,2820,2818,9407,10565,11218,2806,2808,2807,2812,7032,9903,6197,9924,9469,9792,3893,3894,5770,5770,5567,3881,1526,3890,7986,8358,8325,11009,275,11201,8358,11151,11152,11153,11154,11091,8324,11078,8312,11156,10800,8596,11155,11046,4395,9593,10725,10729,8874,8699,8310,4395,10324,10323,10332,3428,11050,541,10326,10325,3883,8244,11161,3428,8330,8337,8248,8318,8326,8272,10828,11394,4614,8824,3883,3888,6872,5066,10892,3895,3890,3891,3888,3896,3889,11589,1770,1765,3887,6493,3897,8274,8271,4936,3883,11251,11229,10925,10920,11186,11184,11182,11231,11177,11179,11181,11252,11175,11176,10921,6518,11173,11174,11037,11183,6519,6523,11178,1704,3442,7698,7843,7844,7845,7868,11185,10924,4297,4298,4299,9631,7843,6220,3883,3896,3891,3893,6493,3885,3890,8273,3887,3894,3897,3892,3888,3884,3889,3895,8274,10922,6537,6505,4296,6506,6536,6534,6535,6532,6538,6197,3515,10923,529,541,531,545,542,540,539,538,537,536,532,543,528,527,526,6042,553,550,548,547,554,9665,10053,10544,10975,11221,10948,549,535,524,10947,8240,6533,6532,6042,551,11241,10194,525,8332,9432,9435,10326,11240,11156,9431,9434,11241,9427,9428,11242,11406,11405,10326,8243,10606,547,11153,10560,8327,8311,9416,9412,9409,11046,11151,11154,10556,10201,10139,11161,11054,11055,11139,11152,10559,10562,9593,9908,10136,9891,9894,10096,10101,10103,10102,11154,10100,11407,8245,9414,8325,8319,9415,8332,8318,8307,8249,9410,8248,9424,8247,9425,9426,8246,8308,9182,9414,10326,11153,272,4146,2781,3874,2779,2780,2785,6443,10963,2787,2791,9436,2778,4224,9589,9183,8883,8330,10926,10927,10931,9383,9867,11109,8945,8946,6688,10232,7600,10928,7636,810,8327,9430,9592,10137,10645,10643,10641,10639,6198,6199,11430,11252,11176,11218,11493,8586,8682,9084,7546,9407,9920,10565,11147,10238,7694,8584,8585,10463,179,178,177,11324,11219,10938,10750,7631,11019,8618,7870,9993,11455,7810,9655,9554,8443,8050,11369,9520,9522,4752,10229,958,3493,7761,8793,9925,2261,8222,9195,3595,7019,9661,6710,3059,6876,1461,1520,11644,9418,180,233,10278,10823,566,173,28,11228,1370,1210,1207,956,1056,466,3872,2451,1741,923,57,1533,3392,1234,1145,3189,2725,1398,2736,9675,1198,2776,1425,9533,2677,2995,3014,4762,4784,4785,173,5089,4788,4690,8894,5756,5112,5143,3189,2992,5756,5251,7172,1537,7304,9453,9052,24,3327,3860,10526,4234,8798,8893,501,4701,5996,10375,3048,11812,5179,3989,766,6261,4708,3830,9378,4779,947,4731,4519,4029,8220,6740,2632,9300,10836,11121,5799,10056,11690,9879,9030,1616,9980,10050,10473,10065,11020,11235,8999,9937,10568,5339,5545,11495,7126,7920,8548,5817,7883,4460,608,2933,1699,6858,3080,7839,9372,10243,11784,1347,4258,9590,11206,10561,11080,11048,11046,11079,9591,10725,11078,10214,10559,10799,8883,10801,3036,6381,7704,10797,11157,10200,10796,9430,11153,10795,10201,10558,9589,10216,10794,8596,10793,9587,11076,11155,11159,10562,11075,11139,10215,11081,8323,9424,8245,10791,10199,9588,10790,8241,9523,10981,8247,11036,8242,8311,8241,10606,8244,11161,11151,8249,8243,8324,8310,11158,3875,10332,8339,10323,10325,8247,8341,10158,8314,11050,8242,8245,8244,11759,8241,10324,10329,10053,6354,9665,11617,10333,10331,11618,11242,10330,11153,10558,10559,8243,8241,10556,8246,10333,10555,10546,7599,10563,10521,1685,1411,10327,10522,8249,8308,8312,8313,8315,8316,8320,8326,1266,810,10502,10565,9920,9407,6425,6424,10325,8618,8584,7870,8586,7546,10238,8682,9084,10488,9867,7631,8333,8329,8331,10336,10561,7638,5332,10519,1556,10328,10489,2605,9383,10545,10821,3875,1770,1768,1771,1765,1766,1767,8007,8159,2932,8825,10427,10612,10866,10931,7676,7600,10930,1768,10929,10799,10800,10963,10928,10840,7676,10927,10926,10828,3889,3890,3891,3892,3893,3894,3895,3896,3897,10725,10216,10159,1769,10849,1766,8585,10637,9679,11069,11019,11049,11047,10526,11008,8002,11071,11137,8154,11048,10526,11055,7810,8971,9165,735,1730,11139,11046,11138,11057,11203,11192,11191,11186,11185,11183,11181,11182,11175,11184,11177,8311,11221,11229,11243,9665,11244,10544,10053,8162,2488,11221,10975,11245,7734,11246,11241,11218,4752,8703,11190,11193,9278,11406,11407,11161,11242,10326,11046,11151,11153,11154,10560,9424,9425,9426,9428,9431,9434,9432,9435,8324,10562,10201,10139,8162,8161,11156,11405,11240,10329,10330,10331,10324,11695,11696,11697,11617,11050,11677,11320,11321,11357,11356,11355,11694,11722,11356,11467,11318,11319,11723,7610,7608,7868,5691,7693,11317,7311,848,7580,3442,3515,1704,7697,7696,7695,7694,11611,11354,11618,11836,6800,8002,11068,11067,8154,11071,11799,11069,10640,10641,10642,10643,10644,10639,10645,10646,10752,11252,11251,11461,11493,11228,2677,7697,7694,7695,11694,7868,10332,11624,7695,11694,3073,10326,10325,6354,8332,3895,3896,3888,3887,8274,3889,3893,3885,8273,6493,3897,3891,8272,3883,3894,3884,8946,10327,10328,10329,10330,10331,10323,8248,10333,10606,9119,8585,9908,10194,8882,8290,8339,9588,9587,8330,9430,9429,8682,11722,11242,11677,8586,8618,9407,9920,9589,10200,10199,10801,10557,11617,11615) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC