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,3744,228,2677,6691,2677,3904,4082,6696,1347,3080,6774,5817,2294,6633,6858,6863,6693,1299,4724,6793,6821,3612,6809,2262,739,608,6845,6104,6006,3115,4432,4566,320,3701,3719,7592,4652,1699,1349,4778,2451,1073,2841,7839,4460,6732,6209,4258,7946,7081,7265,7268,7971,8058,7069,4029,7154,8211,8044,8058,7244,8288,8429,8361,8078,7080,8403,8209,7294,8713,8400,3066,8469,6650,8207,8402,8468,5947,8839,8772,186,8195,8284,8876,5936,8281,7913,931,7884,801,659,3647,5545,971,9249,5961,9141,6069,7718,8468,8408,1163,9560,9743,5956,9458,9480,2329,1906,9028,8460,5460,9875,4710,9874,9648,9876,9877,9878,8445,9648,8446,10275,10270,9132,9133,9619,9620,9621,9622,10575,10078,9748,9793,9746,9747,10292,7671,10947,10948,9609,9611,9608,10687,7262,9610,7241,7672,9878,11062,10965,10943,10906,10881,11187,10506,11045,11096,11059,10941,10891,10026,11262,10879,8573,10888,11018,11370,11275,9205,11277,9794,9756,7077,9675,11332,11337,8397,10676,11369,11469,11539,11542,10678,11266,4227,4226,10703,10449,10854,11410,11553,11614,11675,9877,11627,8740,8568,8424,10332,11252,11695,10325,11319,11696,9624,7172,9232,3559,7165,7170,7163,7171,7169,7164,7174,7173,7168,3115,11255,8228,8577,9554,4463,7166,7167,7677,4473,4470,8662,4464,4486,7070,2823,6443,1741,4645,9892,8712,11527,9509,8946,6688,9867,9383,5236,606,4625,4767,4185,5215,455,3493,2398,1038,768,1830,322,2863,4217,6117,6684,6560,6559,6679,4023,6595,6635,1134,2705,2025,3501,2590,5339,215,6493,444,322,446,3883,249,5070,1917,3698,3241,4099,1298,6832,2458,3595,1559,6779,1498,2261,6248,3550,1257,1215,6560,3702,6588,3037,6732,252,3625,2337,6635,1521,5142,3327,2954,6793,5373,3542,4136,6104,5379,1349,6713,7016,4023,6684,5817,435,766,5339,3159,3437,971,6069,4460,4005,4258,4050,7019,7156,7138,6365,4878,1762,3080,1080,4125,249,752,322,1121,7230,7304,5460,7005,4178,4455,5020,1536,7126,7050,7238,4886,7761,1253,608,1698,4460,5545,7038,7840,6693,7354,7879,5236,2915,3725,7829,1038,7839,2705,7878,7760,7783,1371,6842,4652,7858,7640,361,2635,6663,7920,8031,8089,8094,7992,5349,4199,2387,5070,8095,3701,2294,3162,4218,2590,358,5247,8222,5885,6478,4710,228,5764,2882,4766,5915,8611,1830,4217,2863,6001,7787,6941,6366,8442,4144,8829,6314,6686,2657,8548,4209,5362,6971,8555,6712,8809,2381,8938,9027,4082,9038,8837,7614,1318,8918,8687,36,1127,8910,9030,8947,6117,8901,9079,9195,8999,8902,9186,9052,8543,6981,7550,9220,7615,9086,7883,6642,9200,9248,8500,9346,9348,8805,8935,8800,9363,9321,9353,9453,7582,9372,9386,7758,9213,9402,8919,3165,9468,9335,7221,9558,2698,9471,9606,9541,9602,9377,1277,9552,9607,9638,9615,7856,9634,9554,9654,6858,9406,1699,9769,9668,8514,9825,9600,9800,9455,5484,7910,9454,7017,9374,9922,9116,9308,9221,9835,9945,9952,9964,5222,3302,5210,9986,7830,6824,9834,9814,9212,9937,10021,10018,10019,6113,10002,9910,9884,10001,9928,9896,9900,8933,61,3117,3134,9883,10039,9831,10062,9799,8006,10131,10116,10188,10129,9935,9639,8777,8776,10063,9258,239,9347,9352,8923,10173,10115,10057,10048,6010,10148,10245,9730,9951,10047,9942,9387,773,5692,5743,10243,10046,9879,10288,10283,10227,10130,10505,10284,10374,10528,10548,10373,10526,10376,10368,10375,10469,10674,10556,10394,10725,9593,10201,9591,10139,10562,9983,10199,11020,10938,9589,9587,10559,11028,9833,10892,10518,9407,10871,9588,10268,9430,11135,10894,10727,10472,11156,11021,11122,9832,11104,10750,11136,11154,11139,11220,11218,11154,1699,10225,10649,7599,10211,10738,9389,10956,11010,6845,11314,11324,10830,10266,11018,10289,11287,11288,11126,8586,11233,11406,11360,11379,11299,8390,10719,9814,11340,10463,11361,10565,11353,1537,11442,10526,10904,2992,11437,11378,10895,9193,11396,11382,10879,2506,11304,173,10823,11351,11455,11493,3521,11409,10893,177,178,179,10314,11443,11495,11489,11522,11552,11598,9950,11599,11093,11377,11606,11480,11608,11342,11523,11600,11655,11658,11646,11285,11661,11620,11656,11453,10892,11722,11678,11691,11479,11289,9244,11681,11670,11201,9339,9381,11383,11491,10188,11621,11724,11488,11786,11785,11373,11107,11455,11764,11770,6704,93,10731,10721,11602,1969,11775,11202,11441,11851,9601,11848,11408,179,4767,1506,6559,6663,6876,1520,793,464,5907,6001,308,585,600,6162,6168,358,3892,5647,4969,228,7258,6813,7304,6766,6954,6812,4217,7160,1830,6794,7144,6780,6155,2328,2506,6695,2863,6831,6802,7838,3046,7783,4983,6767,2419,7602,2573,6160,7146,8020,4735,6159,725,3728,6811,8093,6588,7143,6605,6971,4570,6128,8096,8526,6726,8230,7822,8503,8836,6172,7304,8611,8184,8512,7887,8109,6348,8852,8489,7897,8869,6104,8869,8032,7850,6809,8118,6845,8903,6104,9075,9116,4860,8630,9052,3725,7920,2023,8500,7839,585,8948,9366,4220,9354,2925,8933,9369,1490,8955,9541,8806,9069,7022,9543,6135,9453,3549,8543,8305,6117,9647,9648,4765,341,9200,4652,9345,9374,9348,1349,8934,9346,9939,9249,9248,8795,8915,8805,8935,9924,6821,8492,9922,4566,9941,9928,4566,8501,4128,9402,4061,8031,10057,10208,9910,9117,10063,7759,4056,3936,10227,3100,1698,7138,6683,145,6986,6635,6793,6684,9991,4131,10039,6679,9363,7761,9258,10341,6595,7354,10548,7019,10688,8222,8793,8222,9195,9552,9925,10245,9993,5236,9000,9027,9282,10762,9034,3595,10879,10938,10528,10955,768,10893,8829,9352,1127,233,228,11127,9749,9065,3964,4635,4656,5046,5193,7760,11021,9038,8629,11122,308,4023,10246,6314,6779,6169,6674,180,148,6639,180,3493,2261,11324,6686,8808,11324,9379,7147,8923,8781,8257,3059,10572,10535,8539,6792,10573,11213,9467,10906,6713,8769,11489,11377,7077,11220,7156,11361,11439,7077,11361,11439,9629,11018,7077,4537,2294,9055,9204,8048,4046,10915,11124,9639,2019,11353,11599,7661,1895,11287,3288,10719,7662,10623,11125,11521,9638,10623,9220,6713,10042,10623,10042,7125,11126,11724,2923,10895,7084,5368,11678,11760,8709,8368,11237,11692,11501,11693,11803,11867,11868,10630,10272,8056,11867,10689,10623,11502,11777,10624,11647,6139,2882,5997,6155,1108,314,5908,6102,5256,2113,3037,4730,4766,6104,5995,2324,5247,6829,931,4412,1825,5883,2156,6633,1052,4898,5962,6825,1038,6006,3358,6364,7878,4555,7276,2845,6741,8095,8064,7262,8022,4130,2594,8078,1010,8403,7719,4770,2182,8141,8516,8306,1645,4728,4254,1257,4767,4233,8578,1559,5373,8722,8552,8289,8639,2989,8,3989,6154,7374,8841,8095,934,8587,8915,3262,5763,3297,8144,4337,8615,2381,7919,5837,8484,6907,8836,7904,5065,5066,7834,8580,7836,9058,4670,9305,9318,9269,9254,9333,9387,8220,5267,9421,9322,9365,9459,9509,9338,9479,9403,233,7928,6103,8628,4800,9366,9526,9641,9656,9763,9770,9028,9136,9527,9406,9798,6857,9648,9347,9634,9871,9930,9942,9750,9947,2985,9030,3479,9968,10008,9950,9935,6738,8776,10060,9978,10011,61,5477,3933,10061,10079,320,1268,1536,3162,3612,10108,10172,10128,2093,9951,9954,609,9439,9045,9032,7833,2137,10210,10228,9998,10221,1815,10303,1816,9214,9059,8891,3701,10354,10338,10307,10366,10375,9832,10351,8139,10482,9245,9807,8828,10523,10481,9373,2025,10615,585,3904,9043,10666,10648,5795,10258,6700,6548,10569,10244,10568,9904,8900,9831,8837,10548,8925,6713,10870,10880,10895,8888,8901,8902,10857,10767,9086,8089,10702,8800,10911,7828,10619,10620,10705,10621,10899,10142,10903,10935,7807,458,6177,4218,714,408,1084,6349,6642,1881,6710,6741,5953,4765,6709,5949,931,6779,186,867,4597,2520,6789,579,5093,431,6813,6986,4898,5923,6561,6832,6622,6348,7019,452,5769,850,6842,2458,1616,2490,7239,405,698,1151,617,3395,3046,739,5647,6004,6804,7359,3609,7547,1308,6193,7374,7759,582,1461,7760,7776,7872,582,431,7899,6312,7790,7889,7908,8031,7871,8103,7907,1265,698,7889,2521,8110,8222,8214,7962,7953,8183,8388,8195,8182,5455,446,1815,8483,8547,8358,7547,8390,7022,961,8629,8611,8725,8765,2006,2029,8793,7128,1052,8835,2989,2310,6622,6115,6190,6193,7790,5998,2093,8947,8918,2156,9027,5484,244,9038,4185,5542,5906,2889,254,5247,5322,3216,5837,6315,320,5331,6796,3026,464,6700,6866,5331,1462,508,6121,1230,924,4218,5994,922,6364,6382,5956,3542,6130,1645,7304,5996,5909,3037,4109,567,4834,1557,6891,1325,4450,405,2117,1998,421,324,4029,7547,7143,4690,2729,4432,3054,5763,5735,4986,450,4320,4659,4722,2246,6809,7834,5904,1073,8093,7592,7837,7835,7836,1461,8103,8151,7907,6828,4765,3549,7910,7359,637,3014,501,6838,5602,1327,7919,8092,3872,4901,3904,358,435,4056,1119,1121,7861,1215,4983,1029,7812,7783,8617,4731,8629,8793,8745,6642,8555,8837,8836,8869,4566,8919,8840,7037,1461,4730,6397,4950,36,768,8169,9030,9075,9073,8933,9074,9072,9164,9163,8841,9096,9072,9074,9216,9244,9243,9242,7815,4395,8441,5236,9281,7899,9344,2253,6310,5046,4061,6986,1038,4339,2847,8839,8031,8547,7559,9460,9456,9459,9464,9455,9454,7354,7587,6713,3261,6782,8089,2882,1516,504,9497,7833,9479,9546,9757,9647,9463,9814,9635,2989,7804,8970,9810,5881,5885,7548,7873,6842,8280,8291,8818,9038,9334,9078,9614,5915,7140,3395,9345,8978,10004,8504,9990,9637,9888,9897,9910,10113,9900,10114,6002,6981,9967,9603,10046,2446,9753,9788,409,9319,10039,9828,10064,9558,10060,10088,10182,10087,10261,9987,1385,10109,10104,10260,10267,9354,10237,10358,9769,10258,10183,1142,9180,9185,9299,9506,9801,10063,10259,9389,10229,8910,9406,9275,10210,10528,10121,10547,10549,10297,10343,10364,10380,10320,10319,10318,10564,10699,9959,10090,10480,10187,9919,10820,10700,10471,10505,10741,10847,10569,7131,10655,10668,10712,10977,10967,10972,10893,10702,10935,10679,10538,10119,11044,11090,11041,10971,10416,10715,10719,11021,9336,11103,11104,11042,9615,10174,9969,10440,10780,10785,10737,11106,10754,10734,9617,10778,11028,10749,11129,11135,11162,11163,11134,11089,11237,10536,10842,11126,10876,11258,11230,10261,10875,10878,10865,10086,11282,11220,11272,11315,11339,3493,11372,11382,11361,11121,11397,11234,11127,11446,11450,11381,11131,11386,11271,10236,5795,10837,11487,11423,11213,11377,11359,10938,11621,11551,11606,11379,11612,11703,11698,11646,11724,11440,11230,10663,11593,9896,11800,11669,11678,11850,11872,11363,7144,182,1835,5321,2863,4217,2052,5252,2117,4417,1318,2117,3250,423,1831,3520,5305,2985,6845,6104,2780,2785,6996,3070,2518,3555,2342,2374,6999,243,219,1245,6390,7785,7926,7870,6633,7761,4931,7796,6982,7774,8351,4395,7989,7830,7713,7115,7116,7152,6971,501,7878,8048,6261,8503,5795,1461,7761,8222,3059,2709,8924,9362,9374,9374,8584,2706,4861,8506,9831,7107,8251,8948,10265,10306,9748,9890,10555,10479,10577,10862,10937,11325,8208,11497,5252,6633,1537,375,431,1765,4558,3702,6104,5148,714,6785,6364,6962,176,2706,3337,5331,3989,1029,2029,7019,5516,7034,6365,308,6567,1559,2006,358,7235,7304,6001,6718,2024,5915,2024,1439,6793,743,7290,6901,2863,4217,7047,7837,7275,1895,2677,6902,5623,4432,1954,3590,6901,1826,6553,419,7063,2677,7029,341,6860,2956,3760,7879,7840,341,8502,6718,7674,8171,8436,470,8587,8488,8095,8616,8094,8587,8886,2956,3788,6562,6563,2334,5222,3417,3282,743,9002,8997,8993,8994,9003,9001,7233,6990,7783,7029,8617,1416,8870,5765,1577,2889,3029,2766,6824,5692,2331,7034,9002,8587,8993,2957,6790,8004,3590,9321,6780,1568,7712,6902,7029,8488,8095,8780,7619,3564,1131,444,2331,2334,2592,955,9390,2956,2446,9363,1834,971,3418,3479,8923,1893,9463,7787,2454,9511,9512,9531,9532,9528,9551,9568,9571,9570,9566,9002,9001,8094,8095,7000,9531,9419,1532,9321,8996,8094,8834,2680,9783,1163,7618,6882,2698,9981,9982,10005,10004,10012,10013,10014,10017,10015,4422,7907,10019,6828,10109,10110,9947,9982,10108,9948,10118,10165,10112,7830,9570,9226,8845,8461,7674,6556,6557,7618,926,6095,2923,6551,6555,1278,1815,6068,5856,9987,10267,10221,7792,6205,9987,10413,10414,9620,9619,8083,8034,5066,3358,7605,10397,2329,9532,10345,6555,6551,6248,6552,7829,10266,10141,10127,10632,10635,10395,10266,10621,10620,10619,773,9200,9116,8978,9290,6635,9798,8431,9650,7272,9742,10571,10574,10585,10772,4860,1371,3941,3860,5996,2976,5764,6315,5020,3561,4566,252,793,1402,836,4234,5321,3100,606,5764,4969,5286,5837,6779,3037,1907,1137,1690,4875,6686,8215,7156,1176,7840,5541,1177,1190,2324,4766,4223,2381,2882,3525,5795,5543,7875,1835,3921,6635,4088,6639,8004,1439,1163,5373,7919,9073,9086,3625,8901,252,5142,1521,1137,5131,7858,9243,2657,3715,8793,3493,7016,8902,8888,4056,1177,7582,8629,228,6866,9376,8901,9464,8900,5541,9402,9376,7883,6707,5379,7017,8999,2294,8900,7875,8548,6713,8819,5339,9638,2957,9197,9654,5817,9637,1347,5545,7126,9766,9552,3754,9798,9335,9807,9879,1253,1461,1699,9925,2933,7017,7839,9764,8978,4258,608,9921,7126,8548,9454,4460,9680,6858,9932,8999,10056,9661,9542,9961,10055,9993,10036,9929,10134,9769,9952,10116,5986,4805,4701,2976,9421,9453,2025,9273,9904,10063,4209,10065,10229,10244,8151,9897,10079,10212,10042,10243,10244,9665,10053,10118,773,10245,10211,10149,4652,9541,9347,10258,10227,9045,4337,9249,10307,10377,9831,8805,10342,10355,9476,10245,10062,10246,10266,8934,8915,10523,10524,10473,9833,10548,10397,10568,10523,10528,10127,10627,10416,10348,4665,8010,6248,10246,10628,7718,10350,10569,10734,10879,10735,10899,10341,10798,3413,10870,10300,7614,8795,10737,10938,10375,10814,7615,10894,10711,10608,11020,11021,11023,11018,10972,11042,10913,11089,10878,10765,10893,10911,11121,9930,11122,11126,11123,8948,11100,11142,3003,10749,10783,10784,11171,9072,3288,11220,11219,6117,10530,11234,11230,11237,11235,1134,9634,11199,10910,11287,11288,11285,10719,4028,10798,4665,4209,3134,9922,11349,11361,4103,9928,10990,11353,5996,666,1537,6010,6383,3860,4860,5222,6559,7304,5148,5148,3760,231,6942,1869,2446,3454,3787,1738,501,1461,1228,836,3657,6570,802,1055,1160,1568,943,772,743,1441,1277,1727,1915,7864,7858,6852,2592,6827,1110,6845,7856,7758,3590,7221,3844,5623,5765,2654,3303,7034,1577,1822,2685,463,7232,3181,6853,219,5509,8488,1416,2864,3844,3418,360,8094,944,1522,2653,243,341,2469,1575,2334,3482,2956,7803,3788,1313,2571,4219,3989,2723,5148,2671,3843,3304,319,470,3417,1829,3584,7779,4722,5552,4021,986,3351,3778,6643,5735,7784,6849,5170,6570,8616,5070,2454,2706,1893,6573,2456,6562,652,8707,6574,6571,6567,6998,8684,7224,650,7031,7229,7232,7221,6675,7227,3540,6676,6564,444,7063,6563,6568,6575,6565,6576,6883,6574,6735,7228,6678,6882,7013,7690,3415,1856,6996,7757,7687,6999,6997,7688,8726,6992,7689,8147,6990,7223,7231,6994,7681,8148,7001,7059,7235,7225,6736,7057,7692,8993,6885,7684,7685,6669,7052,7234,6902,7682,7683,7226,7699,7233,7691,8919,7237,9003,6007,1834,8994,2151,6676,9002,9068,6860,8997,8996,8814,8324,1586,6569,8618,380,6968,6962,3898,7631,8788,6076,9217,9590,9119,8972,9785,4684,8356,9555,9781,2522,9947,9001,8311,9880,9851,9838,9231,8917,5995,5148,1137,3941,4048,180,6842,5286,6595,8500,4131,7354,3921,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,104,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,6840,6593,7619,7037,5184,9831,8650,9610,10244,10229,9220,10077,10227,9529,7761,9925,8888,9132,10434,10548,10573,10530,10526,36,10592,3080,5795,10342,7617,10659,8927,9187,217,9481,9527,10675,9798,9807,10046,9808,8474,10042,10055,8087) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC