On 1/22/2018 4:36 PM, Cecil Westerhof wrote:
When I do this, I get:
sqlite> SELECT *
...> FROM playYouTubeVideo
...> WHERE key BETWEEN '1' AND '5'
...> ;
1|1.0
2|2.0
3|3.0
4|4.0
5|5.0
[snip]
sqlite> SELECT *
...> FROM playYouTubeVideo
...> WHERE key BETWEEN '1' AND '5'
...> ;
1|2.0
2|3.0
3|4.0
4|5.0
5|2.0
But I want the last one needs to be 1.0.
Something along these lines, perhaps:
update playYouTubeVideo set key=char(61440+unicode(key));
update playYouTubeVideo set key=case when key=char(61440+unicode('1')) then '5'
else char(unicode(key)-61440-1) end;
--
Igor Tandetnik
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users