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,5784,1265,4128,2021,1650,926,1917,1461,3595,986,6190,6609,1462,1084,4767,1681,1461,4209,754,6705,5371,6809,4566,6845,6103,4046,4049,6245,1016,6561,6249,6980,6104,5717,4050,419,6248,6252,1815,2245,6804,6766,6589,6793,4086,1526,768,6686,6588,2706,6679,2417,6635,6856,6639,6684,7138,1270,5148,6726,7156,2342,6674,916,6314,6595,2169,6792,5371,4023,6858,7158,3080,5339,2294,1895,1119,7050,2923,2703,2123,5573,608,4061,2006,752,1349,1127,1253,8543,2933,8683,6713,4460,7138,1432,5373,7354,5812,4048,5266,3080,8687,8978,8925,8548,8910,5545,4652,4566,4258,8905,8795,5817,6684,9086,9030,6635,9000,9050,5339,5020,7126,4460,1349,1347,3701,8904,2933,9196,8688,9079,5157,6117,1299,4553,6696,9353,8632,9363,1298,6632,8442,9258,8102,9406,6698,3195,9200,608,5726,5349,3542,8978,6337,9347,2118,3159,6740,4639,1768,6519,6523,5864,1766,6532,2720,6498,6507,4300,6222,6497,6515,1767,2795,6200,4301,4936,6503,4305,6371,6529,4301,2720,4293,2780,2785,6504,2783,2778,2781,2779,2782,2784,2786,4290,4298,2787,6530,4300,4282,1766,1769,2818,2824,1764,1767,6263,222,3071,2789,6489,6531,4286,6354,3070,2823,1245,6198,6201,6199,6200,1767,1766,6354,3073,7137,511,7299,7300,7134,1767,2808,2803,3888,3885,2791,2820,2801,2802,2805,2807,2806,2794,6546,1769,2826,2827,2828,6514,1245,5576,1351,2869,834,3884,3882,6515,6456,3891,3893,3896,3892,3890,7567,3897,6493,6271,6507,2720,7300,2677,2995,510,6523,6371,6743,3029,7548,6218,6199,6373,6223,6527,6201,810,2522,6354,6546,3070,7751,6689,3073,3071,1769,6750,7599,6746,7870,6749,2018,7753,6751,3889,3882,6599,374,810,379,391,387,6066,384,378,382,375,394,376,6082,1266,7215,7054,3898,1250,4178,5647,7752,6354,1766,7598,7600,7676,7137,7631,6809,4445,4827,4512,6354,3070,3073,3071,6689,550,7677,7168,7167,7170,7165,7163,7173,7164,7959,7922,7054,6985,7752,1767,1765,1769,1766,6168,7986,2522,1741,6354,8233,8232,6880,3071,3521,2389,3070,8272,2822,2823,2826,7238,8245,2728,2893,8294,7787,8432,344,8316,8220,8313,6509,6508,8307,7238,1767,6197,8520,8514,8315,8318,1769,5909,6520,8233,8246,8334,6521,8331,6513,6514,6507,6515,8358,4639,4535,5576,2869,834,1351,1741,8481,6505,6261,3913,3085,8698,8681,3850,5647,8682,6534,6537,4178,6535,8730,8520,8333,8649,601,2170,2390,3610,8342,6641,8596,8691,8814,8817,8815,8520,5996,8142,567,7634,7635,5551,8617,8719,2520,8591,8717,2522,8681,2522,8681,8780,8944,8817,7881,9041,8683,2253,4535,8826,8682,8945,6168,223,9030,4639,311,8358,8698,4834,2992,8175,6691,8727,2925,8232,8551,8681,3913,3172,9390,1232,3165,4178,5068,9736,10297,9390,9951,10364,10238,6971,9334,3646,10353,6209,9934,8514,3731,10164,9084,223,4639,6250,10527,7554,7592,4218,8555,6712,5567,8290,10505,10656,3646,10547,10531,7910,7756,10339,9669,10364,9670,1257,4178,446,5376,222,9543,10865,10654,10877,6611,10296,10786,8306,7636,2749,6843,6004,5996,2992,7304,1537,2473,7548,7205,3860,6740,7238,3860,7840,8220,4437,6122,5421,4218,5770,5371,5576,1462,2342,1343,4570,3863,2455,1461,5576,2269,7307,6981,2869,6809,1351,4535,6809,7020,834,501,7020,5657,3850,6709,2269,1764,7359,4446,934,7546,1038,6599,698,4566,452,3492,6845,6721,156,1271,6723,446,5419,7604,924,5647,1973,4178,2932,1200,4362,5148,766,2932,4860,2006,7631,1993,3830,1439,4901,713,5995,1453,4796,6367,6103,5837,754,2029,5269,7840,6168,5376,6981,7592,6740,7554,7833,6155,7754,1345,7751,7756,6131,5484,1826,650,6565,7147,1085,1086,3850,358,5915,840,7240,7548,6589,6130,4597,2117,2628,975,2555,3525,7869,8223,734,5419,3760,8095,8094,8488,6740,7034,396,743,7594,5602,8587,7783,6712,7910,179,4767,1506,6559,6663,6876,5088,1520,793,464,5907,6001,308,585,600,6162,6168,358,3892,5647,4969,228,7258,6813,7304,6766,6954,6812,4217,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,5305,1038,6669,5647,6998,2932,5995,4796,5148,5995,1351,975,2869,5735,943,6663,4128,2469,1822,2390,7034,1520,6827,3181,1829,7233,3302,3778,2331,7001,4947,3843,7787,1245,2571,2635,6104,7794,3384,6845,6858,7594,4555,5719,1070,3522,7904,6898,7304,242,3380,1738,4788,1126,6381,7238,2785,6110,673,2778,2783,5882,6961,2782,6751,7238,2781,3913,2789,6373,358,6396,6726,6517,1416,2787,6749,6961,6375,6130,3702,7832,3029,7906,2753,6588,6157,6177,5420,4140,5908,7144,7088,8041,6740,6641,2029,7276,8384,582,6633,8082,6118,6349,7238,1516,7941,5582,7101,8049,6780,5884,7911,9139,7589,8305,6141,7634,7929,9611,9610,8947,8628,9235,9031,5908,8580,9547,8389,9755,5996,6940,7020,5657,7812,7943,8109,8223,6971,7548,6726,8296,8230,8049,8526,8526,8064,2992,8357,8357,2473,7110,8512,8033,6773,7669,8503,8503,7074,7304,8903,7714,8051,7714,7272,9030,8960,9040,7903,8420,8020,9309,7897,7897,9525,8961,8961,8961,8280,6766,4320,4535,4535,7833,7833,6971,7833,840,840,6715,6715,7388,7388,4500,4500,8863,9030,9030,7833,2729,8947,8947,3327,3327,3327,3338,9830,9830,9830,5956,6583,2635,6565,6678,6576,6569,6568,6564,6574,8033,7094,7998,7096,7100,7082,3830,5148,7252,186,1662,7840,7840,7879,7878,8095,8095,6740,7238,7238,8094,8220,7649,1537,1537,8109,8903,6726,6971,8816,8230,2374,9030,9321,5924,5912,2024,7027,6658,6658,6740,7838,4639,1145,4796,6867,1498,2632,1210,1121,947,4535,8390,6740,7238,8220,1215,5371,4234,8271,5995,8109,5070,5148,1126,4788,3564,2706,8230,8306,446,6971,1767,501,1769,1768,1766,6740,7238,7985,377,7987,1005,7840,3892,7840,8725,8903,9030,4784,5066,993,7599,435,7079,7111,7294,7124,2706,1398,7270,3891,3892,7295,7291,4178,7082,3884,446,7281,7666,5066,7286,8205,8085,8078,1257,1215,5995,7154,1656,8438,7548,8223,8306,8208,3895,3888,3894,7987,7986,7967,8390,4639,223,223,8412,7985,7967,8358,6740,7238,8220,2117,2117,4701,4801,8409,5602,5602,7251,8204,7089,7076,3884,8547,1371,7243,7971,7249,7702,8164,8166,8167,9735,9176,9165,9300,9745,9873,9874,9030,7897,9875,9744,6382,9876,8654,8989,7198,7195,7199,9877,7162,9878,9879,8451,10056,10056,10056,10056,6763,7194,7194,9172,10026,9302,10264,10272,9581,9132,9133,7190,9619,9620,7196,10185,8208,8656,9748,9622,9621,9746,9747,10887,9177,10390,10421,10419,11059,10881,10833,8267,7245,6388,10947,8469,8470,7671,11187,7268,10051,10575,10575,7665,7703,8585,10891,8468,10888,9378,8413,8383,11713,11587,9738,9259,10623,10630,10384,6919,7680,6926,6754,6759,6925,6762,5068,3702,3913,4563,8306,947,1215,8350,3515,6715,7012,6971,6209,8143,6,5996,240,7304,3860,7897,6766,1537,793,8281,7928,8223,5770,2029,7175,1343,2658,7391,7833,8296,7205,8503,8818,9085,8464,6122,8512,9681,4898,7878,7238,223,8436,8220,8171,7094,7713,7647,7647,5454,5454,6740,8063,7548,3511,7716,8577,5134,8610,7655,9300,2263,9354,5996,3888,8729,391,7548,3890,3885,1492,6749,3889,7987,7986,1462,377,6076,8968,1462,8968,3890,372,6593,387,7576,6593,7576,6593,7576,7985,8271,314,8389,6174,6175,9030,1726,6493,8272,3891,3883,1726,3897,378,8878,8877,7576,392,7599,7576,4473,389,3894,3884,3881,2992,368,2145,376,6076,6361,915,6361,6066,1108,1167,546,8267,8788,8223,390,8223,3892,9537,9547,8789,5956,4979,5956,9536,9536,6843,9266,6843,9266,8858,365,6204,6593,365,6593,6750,8878,9616,6743,6751,8390,8981,8983,6750,9879,6746,8879,6746,8879,8980,7196,8167,9950,9692,8230,9692,8230,9525,7588,6745,6386,6745,6386,6743,9890,10167,6916,7610,6745,10263,9829,8597,8982,6789,8164,8981,8983,8980,5995,8306,1257,51,7702,714,2605,1184,9114,6749,1145,9119,8342,6751,8267,8341,8988,8339,8879,4796,8357,8549,8586,7825,8763,4079,4983,501,4936,2989,3409,7107,2843,6483,314,3874,314,7078,6984,8145,3860,4224,2520,7100,5066,6658,7289,7816,7816,5897,5996,5996,2992,1537,3172,7783,4597,8683,6350,8161,2632,1250,7548,7548,4801,4801,8820,8223,8526,8547,8815,8659,8836,834,7879,2006,2912,650,5877,7718,6940,1038,6104,7840,8103,7203,7919,8149,8183,7878,6740,6740,6997,4178,3131,6740,7238,8220,7903,8222,8793,7833,8615,8611,1416,8886,3595,8095,8094,8488,6365,9030,8993,8587,8681,8698,8616,9195,9003,1152,9052,9117,9321,8817,9001,9300,8617,9463,9463,9614,9552,9002,4109,8918,8997,9925,9879,9879,9879,8211,9783,8770,6646,7913,7913,1371,3850,5947,1738,7605,6656,4320,840,5362,8150,9425,8531,8674,6144,7599,3358,6971,8345,6997,650,9602,455,6810,6770,3515,3889,8111,3882,4769,4724,3895,6725,3888,5927,6971,1462,8436,7012,3884,6450,8390,368,8003,5922,3896,6797,3967,6004,6983,4297,4299,4302,9028,1265,6578,8355,7205,3581,9049,8661,8490,8917,8885,6490,6209,7912,9502,7576,3860,2992,8836,7238,8933,6740,7238,8154,8154,4121,8922,6876,10086,10086,6335,6335,6335,6335,6335,8628,6740,5175,5305,3302,9212,6119,1345,2520,9213,9079,2841,9079,2841,9366,8582,9366,8582,9258,7815,7605,9405,7605,9405,9028,4130,9028,4130,8372,4199,8372,4199,2555,9386,9116,9872,9116,9872,7548,6843,8390,8390,8390,8390,8390,8390,8390,7304,7304,7304,7304,9049,7576,7548,9049,6836,7953,9949,8111,10211,4639,9950,9904,9993,9904,9993,4801,8290,9951,9678,223,9220,4916,1770,1765,9835,1771,8628,1767,8358,1767,8358,10042,2456,8815,1768,8815,1768,8628,1766,8628,1766,9295,8912,9811,9454,4860,8826,9890,9386,10394,4405,9936,993,7135,10505,2117,8947,9463,10339,10653,10649,7003,9536,10683,10518,10002,9900,10368,4769,5770,4801,2521,2522,5647,10526,11266,8223,9116,5839,10368,10974,9983,10904,11443,11442,9669,9670,3849,3564,10719,11101,10316,10736,2164,3282,11657,11673,10093,11451,11659,11658,11660,10375,11714,11314,11681,11703,11494,9471,41,9897,582,11620,10886,11346,9868,9942,7027,11486,10840,8108) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC