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,1699,6102,5995,6104,4395,5339,5817,4639,6364,5906,6103,5916,5688,1016,6713,4800,4827,3542,3625,3474,5764,4784,4087,6858,6691,6782,6829,3554,5175,5965,4424,1755,1764,3574,6951,576,609,2849,5763,4510,4087,4046,1345,6809,6979,2300,6731,458,6845,7358,5961,1988,3719,1993,7214,7019,3704,6795,7839,4224,7605,7890,3823,4774,7810,3908,4659,7920,2643,2658,8196,233,1511,1984,8548,7883,7216,8144,8031,8514,8089,2294,4258,222,2989,6006,7804,5252,1984,1458,1084,8999,8108,4452,1490,582,3492,1823,9028,9212,9213,9079,3712,8224,4613,4704,1300,2849,9116,4082,4136,9372,8559,2491,8358,582,5961,9258,9375,5636,207,8274,3890,3891,3893,539,542,3896,8271,3882,3892,3894,8273,3884,5567,9937,1253,2933,5545,4178,446,3889,9377,9799,9212,535,3244,6642,6891,4082,10000,6858,10228,539,10243,9438,9437,10181,10568,385,389,8858,8789,8515,2356,380,10354,8787,8005,4087,3401,3990,4613,8534,3474,9439,9214,9930,9648,10120,9680,9764,4046,4411,1490,4049,4050,1973,6738,9823,3493,6876,11027,10114,5175,11298,11020,11235,10674,6591,11339,5207,9243,11495,640,5732,2023,6023,2221,6034,8941,9405,7374,11359,984,11413,538,390,6066,540,532,528,11353,6894,5262,739,3850,5331,1433,3368,320,5764,3715,3542,6792,1559,6117,5373,6635,4131,5331,6559,6782,4185,2294,5349,5542,5142,3625,5717,3368,6713,1038,1299,512,2160,5215,511,1521,6315,5020,6639,1347,3037,6693,6595,6548,3080,5339,2933,6858,922,608,6154,24,6700,5247,223,5885,6367,3026,3904,5875,36,5837,6584,30,239,6674,748,1536,1576,736,585,510,6713,6560,1253,6792,504,754,3474,6862,3863,2387,768,1067,1113,1347,1872,6793,1523,7138,4028,1526,1569,2381,4194,321,2660,2419,7005,2639,1055,5331,4126,511,4061,6188,2299,1647,5764,3413,1727,5614,5817,4362,6845,955,7358,6809,6104,4923,1568,741,3419,1823,3561,3933,2976,3701,6699,3936,967,5236,2590,7839,4553,7012,1134,7025,7883,784,1920,7759,3117,7780,3134,7840,3129,7876,7760,7712,7859,7879,7821,7858,7855,6981,6315,4624,7865,7856,7719,5543,6734,2882,6697,7920,7896,6679,4258,4460,6986,5545,4566,7126,252,1268,4969,7354,2244,7919,8089,3100,4128,8000,7156,4901,6684,4082,6337,6314,4730,1073,5047,1439,1127,1298,7550,8543,6131,4886,7840,6740,7238,8220,8215,8225,7827,5739,7559,6117,6365,7981,7138,8900,1311,6945,3195,6478,4432,8888,8902,6136,2018,360,1698,8901,3542,7605,8146,1521,156,9036,969,9200,9279,36,9116,739,2387,6792,6713,9329,9244,9372,9322,9374,2944,3542,9273,7580,7138,1349,9258,1215,8306,6337,1521,6942,8925,7038,8681,9018,9051,8698,9050,8687,9109,4023,1432,8031,1257,9406,7005,6663,6664,4652,8514,8795,8805,9363,9454,8910,9402,9391,9333,9421,9335,8978,9346,9366,9308,9197,8934,9248,7839,2514,8817,5180,9041,2841,2246,4679,4504,609,7354,8254,1005,9249,1586,8935,9471,3549,5334,8794,7910,8547,8955,4765,6780,4194,5215,1576,2117,8915,752,2387,8193,8019,254,5516,4538,6684,6642,5121,9459,2709,4405,2669,428,9600,2123,5602,2118,1762,9604,9606,5379,1681,1572,1498,6874,9627,5640,3613,4099,6867,4056,3457,3964,228,8629,1080,9038,3023,9638,2743,162,9455,1121,9634,7581,1119,9335,5046,9653,9657,6663,9635,9383,9677,9665,9345,466,4788,1303,3511,1215,156,1250,1498,6130,4767,5400,2029,2736,4558,1425,450,5995,3026,4791,1210,752,5729,1762,2743,5431,6490,6561,435,1398,5922,1461,4128,3936,916,5936,964,1497,3558,5251,5629,2054,5924,6986,6710,1433,1537,1917,7100,6632,254,1089,1215,4796,2337,501,7113,4861,7102,4762,1349,4216,5322,7280,4199,714,4220,7054,6707,4519,4401,1371,7304,5371,7097,1145,2023,6264,7072,6104,5535,934,6365,609,4983,7938,4233,52,5430,6561,8306,3244,223,2677,4639,7238,6740,8590,8183,1439,7875,8615,7023,5373,7546,2986,5143,3014,3581,5484,1126,1645,3018,3941,4510,8783,322,2944,766,4770,1787,1785,2182,1782,1327,8027,7890,1366,1970,7374,7077,156,1016,4395,8279,8204,5986,6798,8482,7720,4419,4639,7655,2027,2374,8358,4659,737,6303,6000,4079,8206,1116,2092,217,10145,446,6364,1038,6600,4224,4224,4224,4224,4224,5986,8306,8306,151,7837,1266,7834,7815,7835,6354,8547,3070,7579,4405,3071,1371,1771,1766,6648,3531,3076,8627,186,8659,1461,6947,6103,7836,5763,2546,1016,3809,8583,3908,8584,4659,7870,8793,8716,7816,3536,4227,1906,3346,2467,8586,7189,5385,1887,4216,8825,4339,6824,7167,7580,7170,7993,7165,1771,1765,1769,1768,8578,4931,8437,7166,8627,5371,9322,9757,8780,8816,1993,6367,8520,6548,6715,924,8388,5717,2399,4769,6621,1142,240,8970,6700,6631,9215,840,6006,9229,5484,1591,6264,2644,7144,8821,5052,7871,6774,5371,217,9390,8833,9281,3327,5770,2253,8515,7838,2029,9468,9027,9322,2117,1371,6131,9162,9513,2006,7861,4435,9538,2005,2085,1052,4395,7923,7976,1242,2989,9480,7992,6642,9524,9479,6103,6004,906,9603,3428,9629,317,754,9306,6691,4079,8685,8815,8814,8826,7576,9704,3598,156,1153,9678,8659,9559,9546,9760,1912,3236,6905,4913,7599,9390,9480,4154,9754,6102,2342,8508,2467,6176,9763,9770,9783,120,6977,9782,6602,9014,7640,9344,4563,6652,9762,6623,8352,9812,2843,9830,8685,6841,8292,8544,9006,9879,9865,9866,207,9872,9918,4216,5419,9926,6819,4320,4900,5927,8576,6774,8771,6774,4639,4639,4639,2288,3598,6621,6175,5371,5956,6700,9340,6971,6691,6691,6477,8622,8371,6561,6561,8379,8379,8428,9482,9482,4683,4683,6977,6977,6693,9338,9338,9338,9338,10211,10211,10211,10496,10496,10292,9797,9340,9998,10078,6658,6658,9543,9543,8206,1662,8168,7286,8925,8901,8947,1349,7920,7037,8837,156,6266,4805,9033,1738,2467,9038,6986,8089,8884,320,36,1349,6569,7647,2989,3719,9196,665,4395,9249,3142,446,6266,1439,3523,6863,5331,9195,8915,7019,9464,1215,5732,9376,36,8089,9553,9556,9557,254,9526,6845,1461,8934,4947,4769,9637,9372,24,9639,5142,206,9648,9654,9641,9750,7388,458,947,9824,9779,9930,9543,9926,9363,162,30,145,739,9937,9340,9972,9965,9221,6986,10062,4156,10057,10063,1325,608,7602,9553,9638,10149,93,9764,10042,6798,9635,2976,3878,1559,8358,2594,220,10212,6632,6104,6261,446,1299,7138,7036,10258,10244,36,228,6117,6163,61,10267,501,93,10300,9335,9754,6858,5148,9811,10182,9638,4056,1347,9764,10243,9220,10227,9052,5267,10476,10350,7017,10341,10416,9476,41,10396,10315,10541,10530,10543,9807,10568,308,8999,10127,9249,10548,10657,8615,10548,10608,10523,10622,10569,10652,5795,9107,10528,10663,9937,5513,739,61,10780,10719,10375,1127,1257,10784,10787,10749,10870,228,10893,9798,10894,10669,6696,8193,10895,10672,10878,10737,10870,9353,10798,10883,11021,2706,11028,10856,10964,11041,10879,10784,10871,10748,11027,10373,9406,1047,252,10683,10764,10512,11123,11106,11126,6113,11018,3532,10667,11122,11197,11235,11135,11219,11234,11129,11180,11199,11281,11220,11041,11287,11142,11171,11200,11340,11105,11324,10744,11330,10754,11104,11361,11201,11377,10747,10566,11353,11227,11107,9935,10783,9910,11234,11349,11288,11455,11127,11492,11495,11266,10910,7810,5997,11478,11442,11494,11488,585,11395,115,11489,6696,180,9248,8934,11593,10747,10892,11134,156,3523,11599,6696,739,11324,11647,11491,11396,11646,10246,7761,11670,11644,11550,11689,11594,10065,162,11491,9402,11658,11455,10548,11309,11594,11180,4258,10798,11646,11613,8031,8869,11235,10568,9749,1298,4969,11480,10917,10126,11477,11783,11787,7995,57,10531,11479,2590,10919,11606,10002,11644,5046,4325,7017,11827,10917,11834,228,11871,11838,11764,11819,11835,11849,11872,3904,1253,10065,28,30,11495,10892,9934,9688,3523,9688,3523,9688,3523,9688,3523,9688,3523,6011,8261,1516,1272,8187,2986,7994,6113,8110,7970,8091,7124,6955,8608,8547,2520,1586,8358,7607,7239,6119,8305,6979,8306,2246,7982,6821,1050,2766,6328,1051,7599,7615,1557,2946,8541,8483,7093,8742,8914,1049,6905,2507,6740,9053,8554,8933,9107,6788,9030,458,5052,4154,6261,4639,7238,8220,9300,8761,5063,8651,1556,5165,9259,7619,9381,8628,9336,7910,9327,8290,9465,9387,8208,9450,9538,9547,2253,9331,9647,9652,8063,9754,8542,206,8403,9788,311,9789,2913,7900,220,4395,9257,8763,9889,9046,9933,9967,186,8434,9963,10026,130,7671,2487,609,10163,10050,8439,236,10182,10073,10177,10225,10144,10257,9824,10261,10234,10360,10519,10518,10541,10547,10714,10615,10820,10876,10910,5790,10712,10979,8206,11094,176,11010,10905,11200,9967,7250,11096,8282,7660,11371,8255,6953,5371,8869,6181,9135,9049,7774,4395,4146,10349,9543,2897,10228,9405,1770,9758,10339,788,10309,11010,120,10754,10985,9543,4659,9340,4568,1782,10000,9770,9714,9753,9863,9701,4435,11298,10649,6548,11347,10892,2467,2989,11454,10780,11622,3327,11623,11227,9765,5269,11497,156,11621,10455,11752,11751,11101,11748,11325,713,10670,7374,7121,8048,9389,7931,9574,6769,8077,9134,9280,8782,7115,9095,10024,9828,9539,8908,8169,9665,10079,9529,9674,8052,9679,9754,9665,10003,7363,10080,9573,1173,9679,10075,8169,10084,4535,9888,8126,8125,9665,5059,8946,9189,10084,9554,5251,9676,9557,9325,7981,9526,10080,7909,1823,3856,10061,10081,7807,8737,8175,8206,4770,9503,2032,9968,4230,1487,7150,10270,3511,3564,3189,10275,9547,3896,10274,8767,8467,10008,10965,8063,10271,7297,8641,7298,8712,8046,9203,10789,8394,7262,10356,10449,8205,8468,8202,11553,11634,9095,11038,11683,11362,9782,107,7802,6809,10376,10294,10070,10658,4710,220,10293,10541,10128,10374,10714,9374,8888,10087,10715,10149,4395,10878,7131,10820,2913,9390,10537,10060,5267,10547,10767,9135,10505,6364,9370,10891,9926,10706,7273,6591,5913,6103,9609,958,9608,9546,8358,10814,9510,10887,8578,10704,1487,7669,10694,11332,8048,9954,8467,11187,10011,9955,9611,10881,9610,8048,11124,9509,11125,8410,10401,10623,8199,11514,10078,8471,8407,11411,9793,6690,9056,7289,11196,9573,11539,7271,8422,8472,7268,7296,11692,11712,11671,11693,10357,8419,11096,10863,11225,9659,11763,9581,8285,11631,10629,7656,9561,9204,11754,10409,9141,8400,9187,11500,10275,9134,8426,11065,10807,11767,10030,11262,8709,7674,11711,9821,11686,11713,7241,11538,11335,9561,11926,5402,6832,6691,8968,2328,5371,1521,6645,5582,3346,850,4362,6831,1371,5996,421,6795,7602,4798,223,6890,5927,9694,6785,7214,7639,9900,9386,6687,5543,5142,8876,9244,9362,9389,9387,7144,3728,10129,9497,10116,9951,10001,3081,10313,6130,10312,6889,1453,8828,10956,10517,10240,9959,7783,6633,3414,4834,4399,10818,10131,5947,9354,2467,3878,9545,156,7613,8219,11102,7920,2447,9828,10850,1308,11365,10269,10649,11290,3908,10666,4984,4424,11136,11454,9838,10955,661,1145,11588,11523,10934,11603,1460,1318,8539,6831,8560,6381,271,539,2729,7304,2729,9438,7903,9300,9480,3647,1215,8306,9425,4598,8874,4598,8241,8244,8706,9182,9349,8337,7928,6768,9417,8245,9898,8922,7,9017,9432,9632,9296,10056,9296,9096,1165,222,3883,10292,810,10259,810,6359,9864,10337,6272,10337,10072,9959,3358,6348,10640,8144,4301,10738,10667,10976,7833,9777,10814,11037,11130,11121,10951,272,10937,10954,9880,11323,6354,10007,2530,374,8490,11496,9277,2117,11272,11439,11690,11721,10533,1385,1402,11734,10269,10836,9892,9149,6596,11150,3359,8205,8582,10858,7283,3895,8366,10947,8782,10948,4390,186,6768,1411,7024,7280,535,3896,3887,810,10944,9885,9601,8204,3894,1303,10829,3897,3885,3881,10000,10943,9959,9076,7155,7704,8201,11108,7986,8451,51,3085,7245,10827,4639,8712,7753,8228,8240,7752,10077,7147,7572,3070,7589,11225,11063,8272,6688,9095,10053,9095,10053,9579,11514,8640,10615,10008,8211,9867,10272,10232,10675,7172,10975,4659,11221,9222,9223,8812,9251,8812,9224,10887,7080,7088,10976,7600,11228,10278,9968,3908,11631,10823,10930,9741,8971,6740,7153,11836,11762,7933,7238,9007,11707,7661,6629,1381,5995,5148,1137,3941,4048,180,6842,5286,6595,8500,4131,7354,3921,5088,3976,1461,6792,6707,9808,9464,7875,9661,6632,177,1325,156,4860,5541,8306,1586,6703,9552,3493,4513,4947,4670,10046,10112,6683,4240,4100,4088,4950,145,5005,4740,8819,9983,8846,8829,8890,9258,9925,4355,4566,4337,6679,6710,3904,9910,6986,10229,4023,5331,1954,7005,3026,6863,3744,2894,8615,10227,6684,5542,6694,7156,10523,10063,8031,9373,4233,4767,585,2054,4045,11304,3213,6632,10472,11302,4875,11619,4455,5995,5179,3059,4739,4234,8793,2632,10212,4596,9453,11644,4741,11455,10375,1490,9993,9052,4178,640,10128,8745,10473,4773) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC