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,1770,9407,8584,10214,10335,10215,10216,10213,9632,9868,9501,9084,8682,10334,9430,9587,9591,9593,7764,10199,4804,8323,7762,7570,8585,8719,8717,9590,9535,7569,7568,9588,10139,10346,6371,6518,6519,9119,10202,7631,10331,10432,10521,9429,1770,10565,1765,1770,1771,1767,10247,10637,10639,10646,10641,10645,7844,10752,10753,10552,10257,9905,10644,10750,10328,9631,6201,7870,6199,9951,9407,11046,11055,11047,9949,11050,11056,11054,8324,8596,11019,11072,9084,10800,9590,10801,11057,8584,10324,10327,10333,10329,10331,10213,9906,11033,9970,10043,10253,10255,9907,10256,11030,10925,11032,6197,6198,7698,11037,6199,10552,9632,10561,7772,9493,6532,6534,6535,6533,6505,10239,6506,11069,8154,11174,11175,11185,11176,11186,11181,11183,11182,11184,11178,11179,6198,11176,11151,3073,3070,3071,6689,8946,6688,10053,9665,11137,11139,11037,11174,11182,10924,11155,2787,10466,10920,7171,10922,11186,10829,11138,8272,10828,10519,11178,8232,10827,10546,10520,4390,5332,5297,1685,9149,10522,9137,8274,5383,10925,3884,3881,3073,11375,947,3885,3890,7631,1730,11461,1766,8585,1768,1769,1767,7884,7374,11459,11251,11229,10925,10920,11186,11184,11182,11231,11177,11179,11181,11252,11175,11176,10921,6518,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,11160,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,8983,8981,6743,3883,10222,1730,9165,9601,3898,9534,8982,6742,10167,6744,6746,6749,979,6359,7599,6768,5386,8879,9217,6750,390,8241,8334,10334,10336,10335,9920,10238,10194,10200,10263,8877,382,8330,8320,8339,8337,9891,9908,9113,10202,9111,8242,8873,8872,8649,10152,9112,9120,9431,8318,9114,9119,8326,8310,8247,8313,8309,8308,9633,5691,1685,5386,6195,1765,10546,10545,7845,9633,9903,9905,6533,2605,5386,1769,8824,10546,9909,9137,8824,1685,5784,10522,9137,9149,1770,8917,1771,1765,10925,8824,8489,7869,1967,9031,5770,4714,10645,10646,10750,11167,10925,10922,9985,10466,8592,5810,390,8784,8788,8881,10613,11051,11248,11247,8882,7134,7877,2071,9303,9350,2506,11239,4714,11022,375,8787,372,376,368,381,6066,387,8858,385,380,393,375,391,386,6082,378,8784,394,6270,8880,392,365,8878,8786,8789,10896,11088,11327,11329,11182,11231,11249,6375,11178,6271,6076,379,6537,11176,11175,5332,1411,810,10521,11183,10827,1266,6535,11229,11174,11186,11252,11185,10921,11238,11519,11295,11296,6505,11318,11294,11239,11254,11301,11251,11585,11571,4923,10731,6600,11085,11665,4520,11666,11667,11085,8175,10823,10278,7922,6354,6503,6523,11425,5383,11429,11085,8306,4535,2467,4834,8780,3131,8169,4131,8514,7903,182,2989,182,2522,5484,6117,7146,7615,7121,8910,9245,1402,9406,9116,7920,9431,9734,6744,9178,9408,8246,8244,8087,8067,9225,7704,6380,6416,6612,9734,9178,9501,9806,4286,4289,4304,4298,4299,4287,4292,4302,4296,4305,7311,7610,4297,7083,7697,7695,7696,7868,7694,2951,3442,11184,11149,11183,11181,11252,11174,5297,11182,10920,1704,11037,11179,11178,11231,11175,11251,11185,11229,11177,11176,11186,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,11160,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,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,526,531,542,524,1557,6385,8820,8007,549,6380,11301,11269,11247,11254,11022,735,11568,11650,11317,11318,10922,7083,550,547,11665,11791,11427,6527,10176,11051,11194,11244,11601,5383,3070,6354,10925,10923,810,10827,540,532,8788,394,8786,8858,6270,375,390,6076,548,6066,537,541,8880,8878,7693,11467,11611,8784,8787,391,6836,11081,11079,11080,11878,11877,11602,4282,11296,11075,11876,11077,392,538,11903,11078,6076,10921,11174,9523,11183) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC