Jump to content

Recommended Posts

Posted

Boa tarde... estou aqui com um probleminha.......

Então eu tenho estas tabelas:

LIVRO (#nr, titulo, autor, preco)

LEITOR (#cod, nome, morada, cpost, cidade, prop)

REQUISICAO (livro, leitor, dataR, dataE)

Agora quero seleccionar o título do segundo livro mais caro.

Já cheguei a esta parte

SELECT titulo
FROM LIVRO
WHERE MAX(preco)

Assim como está vou saber o titulo do livro com o preço mais caro...................Agora não sei como é que vou saber... só o  segundo titulo do livro mais caro.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.