Welcome Guest, Not a member yet? Register   Sign In
MySQL ORDER BY FIELD does not working in CI 2.1.0
#5

[eluser]prakash[/eluser]
if your number of records are less you can go with

Code:
SELECT `id`, `image`, `sex` FROM `users` WHERE `id` IN (28,35,40,34,33) ORDER BY id='28',id='35',id='40',id='34',id='33'


Messages In This Thread
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 01:29 AM
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 01:54 AM
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 03:41 AM
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 04:46 AM
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 06:02 AM
MySQL ORDER BY FIELD does not working in CI 2.1.0 - by El Forum - 06-19-2012, 11:48 PM



Theme © iAndrew 2016 - Forum software by © MyBB