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,1656,545,6382,6390,6527,6521,6261,7631,6212,726,510,542,528,512,6869,7770,3515,6513,526,6198,2696,6498,4614,6497,6199,6223,4289,4293,4286,4282,6197,4292,4291,532,4290,842,5903,6546,1266,1165,6359,864,3247,1685,1616,3384,540,5066,3380,543,8244,8249,7189,7184,6042,7180,6201,3581,6656,6652,3879,6733,6653,6223,6218,7176,1245,7179,7187,5332,714,4426,2917,5096,4490,7170,7172,510,7598,7596,7637,7636,8278,549,7188,8599,8246,8328,8342,548,8597,8598,8320,8317,5635,4386,8337,6654,3891,6066,6854,389,8877,372,390,380,381,6376,8324,8323,8325,8243,6377,8882,393,8878,388,6517,8596,8883,8324,8788,6371,8314,8246,8316,8315,8318,8334,8244,8322,6743,8326,8330,8307,8649,8313,8311,8319,8335,8331,8249,8308,8873,8872,8585,8586,8682,7546,7631,8585,8584,7870,8247,8335,8317,8332,8339,9114,9111,9154,9156,8308,8309,9119,9120,8583,8618,9113,9115,8341,9112,8598,9183,9114,8699,8340,8342,1411,9137,979,8824,810,9154,9151,9155,9190,9084,9407,9433,9432,9431,9411,8328,8339,8583,8618,9416,9410,9520,9434,7187,9521,1371,6743,6523,6141,6141,6396,4519,1746,5602,5602,2677,924,924,6149,6377,3895,6622,6622,4788,1398,7670,7670,5995,1764,1764,4079,7593,7593,6151,1730,8220,8220,7072,8067,6809,7082,7082,8233,1198,3803,7068,1992,5998,4770,8326,8244,3850,8245,8268,8247,3392,1234,8246,1049,6659,7093,4519,4519,7878,7878,7656,7656,9425,6521,9381,9381,7108,8002,8002,7761,7761,8793,8793,9548,9548,6146,6800,5997,3872,9189,9554,6526,9376,9376,9558,9558,9537,979,385,8882,380,8878,378,6204,6517,382,393,379,8858,8788,9767,389,7588,372,375,8435,9882,384,390,386,8542,7388,381,9899,10054,1666,7037,7587,9229,7587,9229,391,9856,391,9856,391,9856,7238,546,6658,857,5742,5733,4716,4437,2041,3863,550,8220,6381,553,7539,529,7149,8440,532,539,323,313,397,860,6386,549,8542,5853,6769,526,7704,538,528,525,7704,5853,540,551,864,544,1730,545,531,543,391,535,541,387,536,382,1271,4769,376,524,377,365,376,374,6270,384,2856,8787,368,6066,6082,385,394,6197,8858,372,6076,317,3913,317,3913,6382,6523,8165,375,6526,8496,3879,7588,8989,8530,8160,1380,3823,6854,6391,8159,8157,7300,7605,4701,8785,6144,9437,9435,8244,9438,8340,3879,8699,8874,5770,8316,9146,9414,9409,8700,8245,9436,9425,9408,9184,8883,8247,9182,9415,8332,8318,8324,8326,8319,8241,9592,9183,9428,8248,9431,9894,9150,9143,9534,9190,9908,10045,6768,9300,7632,9154,6396,4501,10056,9792,9891,9155,9156,9217,10202,9156,10198,9854,9217,9502,10193,9502,10193,10197,10195,9147,8333,8335,10099,10102,9151,8330,10218,10147,10333,10322,10323,10217,9412,10102,10336,10332,10334,10101,10331,10100,10324,10140,9433,10213,9407,8583,8584,8682,3896,3891,8700,8315,9182,8315,9182,8247,8340,8700,9408,9425,8324,8244,8325,8246,9233,9587,9183,9426,9111,9113,8249,8248,8245,8241,8873,8872,9427,9433,9436,551,8882,9113,8243,9431,8323,8249,8599,8333,8330,8337,9426,9183,9184,7693,1768,8307,8309,9416,8246,8335,8241,8315,8326,8700,9415,8312,8311,8316,8313,8322,8331,8327,8334,8336,8320,9424,9428,8317,8598,8245,8597,7546,8583,8584,8585,8682,7631,9407,9517,9520,9112,9119,8247,8314,9409,8272,8872,9894,8342,8649,3359,9182,9407,1768,8088,3071,6688,8681,8817,8698,10753,4512,10232,9867,8944,9084,8586,8332,10645,8875,9114,9120,3885,1766,3882,6354,3073,3071,7751,4512,3070,6689,8244,7752,5298,7752,8241,7072,8246,8311,8682,7636,1368,507,8704,1257,7238,8174,7580,7881,272,6204,8306,446,1215,5995,5732,7837,9037,1165,7835,2023,8598,8840,8319,640,8247,8441,8425,8407,8439,8404,9138,9297,9187,8400,8568,9795,8794,8410,9564,8413,8782,8782,8451,8577,8208,7836,9372,1347,608,1253,4258,9937,7920,10232,10243,8402,10095,8580,9560,10401,8450,9313,8407,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,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,10330,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,8946,9410,5853,8627,5853,9426,8088,8944,7881,10099,6740,10101,1932,7195,3898,9156,8988,7199,9409,8882,6928,9173,9172,8700,9408,9176,9536,6768,8971,1730,8387,8858,9146,9145,9147,9144,9143,8881,9150,9190,9191,240,9411,9151,8987,9192,9767,8986,8654,8656,9592,8530,8529,536,535,7694,7695,7696,7697,3881,3884,3888,7868,3890,3883,8531,3882,3895,3893,7196,7198,7702,6937,7196,7198,8655,8665,8581,9993,8879,9088,9178,7705,6270,9633,3896,3894,9177,9175,1765,5386,6656,6985,9217,8168,2856,7870,9154,9892,10100,9155,9792,392,386,9891,10097,10099,9894,9906,9891,4305,8242,9903,9951,8274,3887,3885,10136,10147,10102,9909,9908,9950,379,10193,3889,3892,9535,9535,9114,9592,9410,8245,8323,8242,8599,8320,8332,10153,10200,3442,8700,7696,9424,9407,8334,8682,7546,7631,9084,8874,8318,8584,8316,6496,8317,8597,8335,10217,10217,10214,8598,9114,10216,10215,10336,10101,8584,10213,8586,9182,8310,8307,8314,8244,8307,8311,8308,4305,979,10521,9729,10545,8313,10334,8309,8312,8336,10335,10607,10522,3070,6354,11069,8154,11071,8002,11067,9720,10868,10526,7752,7753,6688,8946,8088,10486,6426,6854,6545,6425,6423,6421,9087,6922,10489,8267,6426,6424,10486,11817,8241,9410,10099,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,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,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,3897,10102,9114,8331,8336,8529,8335,8530,10322,8832,365,3893,10334,10335,9633,10100,9632,10607,8307,8273,9411,6199,10153,9631,10332,6200,10152,6197,3897,6198,8274,4304,3884,4305,3889,4291,3891,4292,8272,4286,3896,4300,4298,2520,3895,2522,4299,9483,3888,3889,4293,3881,7963,3885,4294,3894,4297,3892,4287,3883,6493,9192,3887,9409,6538,9182,6537,8334,6536,8874,6534,8599,6506,6505,8699,6533,8700,6532,6359,810,1765,7808,1770,1771,1767,1769,10799,1768,10551,1766,10336,10101,9418,9412,10102,9533,3872,8586,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,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,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,10238,11218,7631,8729,9920,8586,8307,10101,11138,10333,8875,9114,8242,9182,8341,10217,10334,9436,10336,10555,9412,8585,10728) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC