Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
News Update Denis
drop table if exists news, t_news; create table news (id int, orderby int); insert into news (id, orderby) values -- изначальный порядок (5, 1), (3, 2), (4, 3), (1, 4), (2, 5); select * FROM news order by orderby; CREATE TEMPORARY TABLE t_news (id int, neworderby int); INSERT INTO t_news (id, neworderby) VALUES -- новый порядок (1, 1), (2, 2), (3, 3), (4, 4), (5, 5); UPDATE news n JOIN t_news tn ON n.id = tn.id SET n.orderby = tn.neworderby; select * FROM news order by orderby;
run
|
edit
|
history
|
help
0
ITM_14210069
list with indented categories
JA
practice
Select state by json
emp
mywall
collate reservations
poi
akshay dbms query