• 0
Sign in to follow this  
LukeSkywalker

Mostar Os Ultimos 5 Registros

Question

4 answers to this question

Recommended Posts

  • 0

isso mesmo..

use top

select top 5 * from tabela

Share this post


Link to post
Share on other sites
  • 0

Se esta instrucao acima tenta esta aqui oh...

depois de abrir a conexao com o banco de dados faz assim:

'Aqui diz que exibe 5 registros, serao ultimos se a instrucao de selecao for DESC

for x = 1 to 5

if rs.EOF then Exit for

resposne.write "alguma coisa que vem do banco"

rs.MoveNext

next

Share this post


Link to post
Share on other sites
  • 0
Guest rmanelici
Pessoal preciso mostrar apenas os ultimos 5 registros efetuados...

Alguém tem uma idéia pra me ajudar ??

Agradeço antecipadamente

Uso Access

SELECT TOP 5 tabela.campo1 FROM tabela ORDER BY tabela.campo1 DESC

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this