Page 1 of 1

ORDER BY name ASC

Posted: Mon Feb 13, 2017 11:10 am
by Armenhui
Hi all,

I use ORDER BY name ASC Sqlite command in my code, for getting form names in alphabetical order, it works on Desktop environment but on mobile devices (iOS,Android) it doesn't work.

Full select code is this

Code: Select all

   put "SELECT * FROM form  INNER JOIN icons ON form.iconid = icons.iconid ORDER BY name ASC" into tSQL   
   
   put revQueryDatabase(sDBID, tSQL) into tCursor
   put dbSQLToArray(tCursor, tFormArray) into tError
   
   if tError is empty then
      return tFormArray
   end if

Any suggestion will be helpful.

Thanks,
Armenuhi

Re: ORDER BY name ASC

Posted: Mon Feb 13, 2017 7:54 pm
by FourthWorld
Where is dbSQLToArray defined? And can you describe more specifically what "doesn't work" means in this case?

Re: ORDER BY name ASC

Posted: Tue Feb 14, 2017 12:24 pm
by Armenhui
I understood which is the causing the problem, when the user insert form name in lowercase to database, and then select with order by ASC command it does not work because the database is case sensitive. And user needs to insert first letter uppercase word