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,6173,1313,6563,6978,7024,6189,1407,1441,6181,6546,1165,4450,3073,6654,3115,6204,7748,360,444,3041,6732,8118,4986,778,8358,7077,8222,8738,8765,3070,1537,7835,9052,435,8439,7304,6870,8526,8526,8526,8048,10010,10377,10591,10592,10467,10587,10692,9300,8783,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,8329,8246,8328,8342,548,8597,8598,8320,8317,4386,8337,6654,6521,6719,6761,864,5691,6527,1165,6522,6518,6538,6520,6218,4282,397,6985,6719,1767,1704,4298,1685,7576,1084,979,6656,3442,2951,6800,4121,6376,6768,4296,858,397,3875,4286,4289,1967,3863,4121,857,6985,5297,1411,735,8245,6521,6527,397,7201,7599,8243,6261,6512,8314,8318,8317,6359,8334,8320,3875,8582,4931,8249,8490,7365,3510,7751,8729,8694,8692,2779,7300,2828,2783,2826,2827,8597,2815,4804,7180,7184,2803,2805,2806,2808,6222,8654,8655,8816,8696,6521,3828,6542,6381,344,8531,681,6376,2876,8355,8353,9343,8874,9129,6444,6409,8698,2218,1266,6276,9041,8324,7721,810,2208,3337,6540,8882,382,1084,3327,9949,10037,10034,7721,10032,10263,7204,2169,7697,1704,7693,7840,10696,3327,8490,8507,10698,10579,6925,8156,1084,7721,7966,10983,6988,6922,582,6929,6925,11406,11407,10324,11677,10742,11427,9962,9888,9403,9771,8831,6806,9872,6831,8520,8815,7970,9884,122,9898,4386,9790,9835,2761,10181,8814,8730,4512,2024,10236,6839,8826,7824,7820,9786,5917,9883,9967,9202,10182,9612,9736,9959,9868,2168,6850,8541,8389,9767,9310,9627,9117,5371,389,3073,6354,3070,6689,7753,8088,7752,8822,2999,8172,5363,8627,9037,3071,8780,10519,9870,8515,9496,10685,9391,11074,10868,10552,9168,10041,9295,10672,10673,4510,5872,10961,11073,7130,9838,8972,9215,1770,8531,6501,1765,1771,8274,1769,1768,8272,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,10330,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,8899,10796,10797,10926,10975,10930,7600,11109,10928,10927,7676,11082,10931,8681,6221,8698,6223,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,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,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,10331,10333,10158,10326,10324,10555,10335,10336,8591,6359,10725,10729,6510,6508,6509,6507,10519,9493,6532,6533,8899,11055,7189,11015,7185,6654,8897,11013,4386,7187,7184,11016,10278,10823,10924,10920,6200,10925,2605,9909,7845,7844,10922,11037,7764,7843,7568,7570,7569,7764,4804,7567,9632,9633,6511,6515,11138,11139,8662,9232,2789,9536,2799,2816,4473,7165,2806,2824,7173,7174,4470,4486,7166,7168,7169,7167,10213,4463,4464,7163,7164,7170,11030,11031,10251,10254,9907,11032,9906,10043,10253,10256,11033,9592,11032,10255,9907,9970,10251,8246,8247,8241,10606,8245,1765,1770,11203,11204,11205,11207,11208,11209,1765,1771,1767,1769,11206,11208,10463,7870,7604,5657,8883,4486,4463,4464,8662,7165,7169,11255,7168,11251,11252,11176,11186,3070,6354,11177,11175,3071,3073,6689,6688,11109,10232,9383,9867,7676,10931,10930,7600,10157,10155,10154,8432,9670,10156,9669,9670,9672,11178,11231,11229,11414,9665,10877,9720,10956,8717,8719,6730,11374,10827,2605,4390,10545,9137,10827,11221,7696,10925,11178,11179,11183,7693,11037,11146,7870,4294,7189,11015,11148,4386,9909,11331,10889,10920,10475,7697,4,11255,10863,10835,10921,10923,10486,7694,2605,10828,979,9149,10545,10840,11177,11375,10075,10520,1685,10521,1266,4390,4282,1411,8696,8695,8654,8656,11175,5297,6359,10827,11249,7808,9137,5332,6995,8694,1769,1768,10522,10922,11154,8655,10027,3442,6520,810,11251,10029,11317,1685,10546,11185,11182,11181,11186,11318,11184,10924,10639,10641,10645,10646,10643,10642,9880,10644,10647,10753,8693,11458,10644,10822,9933,8694,3895,8692,8655,10645,10637,11252,11321,11176,11590,11432,6354,1766,8946,6688,10331,9794,7881,7753,7752,10053,3070,9665,8627,11584,9679,9867,10544,10975,6689,7266,10927,3073,10926,7676,10930,10931,7600,11109,8727,8088,10232,3071,11582,11578,7188,7176,7186,7178,7187,7184,8897,7181,11419,7180,6652,272,11422,11013,9037,6654,11148,10928,11016,11221,9250,8944,7183,9223,8945,8943,8011,8247,11431,7182,8585,11418,510,11149,11601,9383,6653,11723,11579,7179,7185,6426,11019,11218,11493,11722,6271,10329,10333,8241,10332,8337,11420,11465,1303,11176,11650,10327,11427,11429,11463,10931,8727,9920,11421,7870,10323,8883,8310,10565,11147,4386,11464,10238,8333,10555,10640,9407,10216,8308,8314,11146,8244,7151,7024,8318,8248,8585,9120,11466,7663,7103,3874,10519,10641,4146,10639,8880,394,10643,10752,1266,11799,9037,8787,10637,10647,10640,11723,10646,11321,11836,10931,10463,7753,7752,8325,11624,7604,8088,7600,9665,10975,10053,8627,10544,3071,10644,8944,8943,10642,8727,9383,9587,9867,10232,9589,8945,11221,8618,8682,9084,7172,9407,10238,11019,9920,10565,9084,7631,11218,7184,11016,4386,7179,7189,6652,7178,7182,11240,510,8897,7770,7180,7772,7771,511,512,8946,6654,11013,6688,9473,11014,7181,7183,11354,7176,6653,7188,11419,11421,11422,7187,11418,11420,9407,9084,8682,10565,10238,9920,11146,11147,11148,11015,11082,11392,9437,11019,7998,4386,9129,11218,9671,9670,9669,8946,7186,11464,11493,11462,11463,8172,10750,11431,8007,6596,9233,10433,11017,8971,11430,11414,11429,11321,6836,11498,8610,11446,5988,11521,10472,6521,11181,11487,11495,11427,1347,5339,5545,9084,9920,8682,11362,8681,11109,9958,8698,11468,848,9492,6216,10864,11269,11649,11349,11664,6497,11377,11378,11678,11069,8154,10042,9638,9220,10941,11493,11647,11349,11724,10895,8900,9638,9220,10569,10787,10856,10042,9904,9086,252,5373,11126,11678,6713,11237,51,4082,7550,8837,5193,3018,10367,8780,4401,10824,24,9896,11355,1770,7184,8306,6713,7185,11016,11647,11463,11464,7176,11488,11664,5255,11876,6800,28,10942,9492,11093,524,543,553,539,535,529,532,554,10325,3327,9946,5435,10328,10330,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,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,9534,10822,3897,10980,368,1770,10239,10821,8232,11255,10443,10612,6270,8878,9483,9143,6749,6197,4297,9155,3881,7632,9217,4296,11320,4464,6742,9156,4301,6745,4293,9154,8983,9231,4298,8980,10957,4292,8879,9151,4300,10646,9147,4305,9144,10640,4294,10645,9633,9146,8729,6743,10639,4289,10752,10753,10642,10641,11427,10644,9792,11081,10643,10647,11080,4304,11321,4390,10545,10828,11076,11077,8982,8981,10637,11432,10520,9149,10827,10646,10752,11320,2605,1266,9137,10637,10647,10639,9949,1765,1770,11321,10645,11432,4390,11017,1685,11466,6484,11218,8585,11723,6526,6520,6199,6200,9632,9631,10098,6197,10433,9885,6198,6201,6522,7610,6527,7311,6995,6234,6517,11182,11037,7694,11184,6376,11185,11249,6499,11181,11183,10426,10812,11430,7697,11420,11431,7179,7180,7178,7187,11069,11177,7695,7868,3385,6800,6103,11385,7610,11052,7311,11365,11251,11421,11130,11419,11422,7892,11013,7697,3997,10981,7696,1927,9555,10906,11187,11463,3997,11116,11269,6653,11063,11376,788,4386,7172,11402,3442,7186,7286,10272,8228,7715,10980,10850,8364,7176,11370,11431,8280,11515,9082,9473,4558,11539,11497,9500,10433,11556,7890,5763,7269,9959,11496,6873,8965,10655,176,2145,10655,176,2145,10655,10805,7178,10480,11365,11795,1016,11780,2791,7179,11150,11768,10526,11746,7374,10840,8191,3890,7987,7808,11209,5297,8682,3896,11215,8255,11307,10646,9129,3358,8244,6688,11322,8897,10520,11049,7176,8874,11013,8618,11015,7632,11432,11414,11463,9865,10932,10984,11204,11147,10326,11205,11418,9524,9863,8963) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC