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,8340,7194,6386,7196,6191,9111,8599,8248,9165,8244,8883,9114,6146,8246,8881,1266,858,9119,9120,8341,8307,6375,8247,8311,8699,3891,8700,8242,8873,9425,9424,8337,9433,9432,9431,8334,9534,9536,1462,8326,3402,9592,5770,9114,9414,9411,8342,9518,9427,9144,9522,9517,9426,8332,8335,1990,8598,9412,8249,8317,8328,9409,6382,8245,380,8596,9436,9386,9428,9480,8874,6139,9500,9183,9535,6371,9590,381,9591,8333,3883,9588,3891,3882,3884,3892,3881,6526,3890,3896,3893,9587,3894,8168,8597,8323,8243,8241,9589,9588,9416,8326,8325,8319,8316,8329,9434,9408,9412,8324,9908,8330,10102,10101,9868,10096,10099,10137,10139,10140,10147,10136,10138,10152,10153,10151,10198,10200,10195,10199,10202,10213,10217,10214,10216,10201,10215,4294,10194,10218,8649,10197,4296,4291,4292,10280,4282,4293,10098,4293,9633,10098,10333,10331,10333,10331,10332,10323,4305,10324,9429,6201,10336,6199,9631,10322,10193,10100,10551,10328,10557,10560,10563,10607,10555,10556,7189,10326,10327,10562,10335,10103,1770,1767,1771,1769,1768,1766,10646,10643,10753,10647,5756,8894,10645,10639,10641,10752,10640,9880,10644,8887,5863,6820,6727,10874,10962,11073,9950,8302,9061,6740,6191,6931,6928,6938,9089,6936,653,6388,8387,9733,7703,6271,9734,6414,8349,9932,9735,6517,9850,6375,9852,6989,9729,9811,6234,6191,6531,8523,6519,2720,6372,726,6396,6966,6995,6376,9408,8244,6518,7196,9165,6371,7200,9909,9903,7845,6968,6604,9520,10194,7190,6383,10201,9905,10218,10264,9734,6937,6934,6423,6359,1616,979,8824,9892,6422,6519,6768,1266,7808,5297,1165,1411,810,2720,6518,5864,9149,10045,9165,9500,10044,6372,9432,1967,4714,9120,9119,6656,10336,10332,3625,10323,6146,1730,8243,10324,8341,9175,6151,7191,7610,10115,3542,1521,7610,7311,6371,5691,7697,7694,9499,10419,10431,6989,7567,6271,7569,10426,7614,9904,9220,10244,7985,10323,3885,3884,3893,3897,6493,3894,7695,10325,9592,10147,7696,10327,6740,24,9593,10333,6519,6372,7868,10645,6518,6371,10642,3442,6517,10103,10647,10328,3515,4282,10563,6234,6375,7238,10637,10728,1704,10726,7608,8881,7693,6989,10555,10559,9535,10336,10336,10801,10728,10800,10727,10558,10335,8589,2820,2828,7987,7986,4291,7568,10448,10325,3327,9946,5435,10328,275,10333,10331,10326,10327,8333,8332,8584,8585,8682,10565,9407,7870,9084,9920,11019,10565,10238,8584,7546,8585,7631,11218,8586,9151,7178,11203,6652,11204,4386,6654,11207,7182,11205,11206,11013,7187,11209,5635,11322,11146,9517,8321,11148,11138,11147,7184,8699,7185,9424,11016,8328,11422,8242,11421,9415,7189,9416,7176,9409,11418,11240,7179,8332,10336,8330,8597,9428,9427,8249,9535,10200,10139,10201,10197,10215,1768,8387,381,380,10199,375,7188,394,372,376,10217,176,9430,10322,4390,10545,1411,9137,4512,10521,10562,9587,10556,9589,9588,1266,8334,8337,10559,8342,10558,10557,10607,9429,10463,14,8341,10555,9593,10194,10561,9431,6066,9426,9436,10552,10551,10218,384,10332,10331,4304,390,4684,9424,9425,9483,9433,9427,10563,4302,10606,4286,4287,4291,4305,10728,7963,10519,1557,7698,7844,7311,7608,7610,6498,9631,7693,7694,7695,7845,7843,7696,7868,9536,4804,6653,7176,7179,7180,7182,7187,6652,7176,7178,7179,7181,11015,11014,7183,11013,7189,4386,6654,7184,7185,7186,11016,5635,8899,10796,10797,10926,10975,10930,7600,11109,10928,10927,7676,11082,10931,8681,6221,8698,6223,8584,10251,6023,10193,7917,7054,10332,10562,9429,10139,3071,10559,8618,10557,10726,10215,10325,10326,10327,10322,10218,10328,10334,10331,10333,10329,8943,8944,11019,8885,7752,11033,9970,11047,4923,8787,9555,9522,510,694,681,391,8880,378,365,372,385,9231,389,8878,381,6066,9150,9143,1769,7881,380,11022,11057,11247,11269,10176,11238,11254,11296,11051,11239,695,9031,8244,10555,694,10801,6540,9429,6544,11157,10199,11218,10556,10251,9970,8784,9906,11151,8882,8881,10463,11207,8343,10214,11154,10558,8883,6270,10216,9184,549,393,10800,384,11407,11392,9587,8323,10561,11299,9147,9154,9155,11078,9156,9792,10957,9217,9151,9146,11405,387,9191,8858,8789,386,8788,375,382,11209,11052,11294,11320,11461,11406,11462,368,461,7861,4259,11077,4251,6788,11081,11079,3895,3893,3891,3887,3894,3890,3888,3884,8272,6493,3897,3896,3892,3889,3885,3883,10607,10551,10322,10686,3066,10162,10565,8584,8682,10606,9407,10545,8586,10726,10336,10519,10728,11017,9679,10238,10970,8699,11057,10198,8618,7870,10931,8241,8244,8598,8597,10750,8585,6497,9084,10565,11149,6215,11218,11049,8682,8244,10325,10323,10328,9951,10326,10324,10331,10158,10329,10333,11007,10546,11050,10560,10555,10327,10159,10137,10138,10218,10563,8873,8700,10728,10099,9894,10198,9435,10322,9436,10140,6359,9434,11138,10136,8649,10202,8872,10331,10323,11049,10324,10329,10333,10326,10217,11137,11324,510,8824,7058,7752,10731,10305,7753,8088,4320,9951,11602,11601,7374,11320,11588,10305,11611,11723,11784,10646,11321,10752,4512,7751,7972,8681,7973,10647,10364,10822,10920,840,5380,1371,10335,8326,10099,10555,10322,10218,9119,10332,10323,10325,10326,9592,10326,10327,10193,8649,8872,8873,9113,9112,9111,9120,10328,9414,10100,8320,8319,10551,2605,2605,10324,10329,10728,10331,10334,10726,8312,10103,8313,8599,9183,9409,9411,11085,11082,10159,9410,8290,10606,9770,10056,8247,8314,10375,1770,9052,9453,1765,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,10329,4386,11015,10331,10098,11014,11016,10323,10443,11022,11154,11148,7186,7187,10215,10607,7176,7180,2799,11157,7179,11160,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,10239,10981,3385,10323,979,10520,8584,8586,8682,8585,11019,9343,9084,9407,9920,7605,11050,11057,10331,9119,8714,8015,10324,11218,10329,10328,8243,11155,11156,8241,10606,11161,11407,6278,8323,9791,9432,8618,11218,11493,9534,7972,7973,10565,10559,10327,10238,6354,11240,7751,11405,3071,3073,6689,4714,10444,11254,11299,11050,10323,8980,6745,10555,11149,10325,10327,10328,10329,10331,10333,10324,6216,6222,6220,6501,6499,6214,6221,6218,6496,6498,6497,7698,6223,6200,9633,11238,4305,4296,4291,4304,4289,4292,4300,4298,9483,4293,4294,4297,4301,4287,7753,4299,8088,7752,8627,9037,11185,9665,10053,10544,10975,11221,6688,8727,8946,9383,9867,10232,8943,11836,7753,7752,1769,6197,6198,11221,6354,10822,10975,10981,8627,6689,7752,11242,10522,6199,10327,6201,6197,8856,3073,9412,11240,5297,11137,11138,11149,11204,11301,11587,10232,8585,8584,4293,10828,10836,11690,7610,6834,10232,9867,9522,10292,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,11160,11240,10329,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,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,11160,10557,11617,11615,3897,10647,3885,11722,11427,7721,10520,8436,11677,10828,527,7986,7956,11319,11723,9905,549,8247,11299,11185,11050,10326,10327,9909,10433,10238,3066,11182,11587,11209,11205,11203,9518,3891,8339,11204,8274,4464,11407,7677,3888,10562,11425,11184,4714,3894,7546,6520,8326,10336,8244,8585,11181,7568,3898,11175,11183,11176,7764,8271,3896,6197,1770,10753,9407,10687,1765,7631,1771,10644,10642,9520,1767,9084,1769,10647,8586,1768,11321,11427,9217,1766,379,6354,11432,11218,3073,10645,3070,6689,3071,8618,10639,10752,6688,10463,10643,11320,9633,10641,10332,10323,365,9231,10325,9665,10053,10957,11650,10975,10544,11221,10326,9144,10331,7753,7752,11677,9792,9147,10327,9217,10328,8627,8088,9156,9679,9037,10232,10329,9867,9383,10232,9867,9383,10232,9867,9144,8944,8943,10463,11085,10637,10333,4701,11677,9912,9911,11723,9232,11618,11493,11799,11050,9147,11354,8727,11069,11836,6800,554,11001,9473,11878,11877,11101,11587,4282,11898,11899,11876,9522,8273,10053,3881,545,374,9517,535,9518,11836,11696,10544,7753,3884,11242,7752,9037,7546,3888,9521,3889,10827,3885,10565,11069,6925,8154,6922,8002,8267,11067,10390,11071,9088,6800,6426,11068,8156,11182,11183,11184,4558,11181,8943,8944,6932,6354,3070,3073,3071,7881,8945,6689,6688,7753,8946,7752,8088,8627,9037,9665,10053,8946,6689,10544,10975,6768,11221,1303,6926,11355,11354,11356,11461,11357,4785,11082,9383,9867,11085,9473,10232,8203,9633,9632,8362,11357,11356,11109,6198,2779,6443,2806,6197,9669,6200,8693,4512,4316,8692,11581,8694,8656,8654,8696,8695,8200,11578,8203,8655,4645,11579,3719,11582,3115,11580,11583,3559,11354,6520,11355,8203,11356,8656,11357,8696,8306,10331,1257,10332,5995,10328,10327,8241,9624,10326,8705,10323,507,11242,9626,8704,11759,10333,8174,4046,10325,4512,11677,11320,11050,10326,10637,10646,7808,9426,8333,11161,10332,10325,11759,8244,8339,8243,9427,11138,8246,10329,11615,10323,10217,11242,10158,11050,11677,9434,5389,10333,8649,9435,10326,10327,10202,10324,9425,8249,8597,8241,9951,9386,9389,3282,9387,9959,2753,10041,8933,3878,10121,7131,7019,7904,10072,7761,9334,9967,10247,8554,9969,8995,9936,9931,9052,10297,9453,10375,9872,10394,10492,10353,10314,10395,10320,10396,10663,10495,9215,10518,10093,10505,9107,8516,10712,9295,10894,10820,10974,10819,6527,7592,7554,1990,6687,10914,10971,7754,9193,10754,7640,10679,11201,10830,10548,10892,10649,10912,11226,10236,10145,11169,11348,11199,11234,11272,11388,10566,10234,10875,11436,10940,11266,10721,10537,7808,11291,11347,11446,10832,10041,11438,7374,10464,11551,11663,11741,11612,10328,10329,9120,9119,9431,10323,10647,11320,9433,9432,8316,8649,8872,11407,11723,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,11160,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) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC