Иоканаан Марусидзе ★ ★ ★ ([info]g100m) wrote in [info]penis_19_cm,
select test.id + 1 from test left join test test2 on (test.id + 1 = test2.id) where test2.id is null order by test.id limit 1;

Как-то не особенно тривиально получилось. Хорошая задачка


Advertisement


(Read 13 comments)

Post a comment in response:

From:
Help
Identity URL: 
Username:
Password:
Don't have an account? Create one now.
Subject:
No HTML allowed in subject
   Help
Message:

 
Notice! This user has turned on the option that logs your IP address when posting. Help
Create an Account
Forgot your login or password?
Login w/ OpenID
English • Español • Deutsch • Русский…