help in showing results of database query

  • Thread starter Thread starter andy
  • Start date Start date
A

andy

hi i connect to a oracle database and i i do the
following select
select distinct(book)
from book_table
where trun(date)=trunc(sysdate-1)

it returns a column of with 3 rows in it
what i have is a form that has 3 text boxes on it
i want to put the first row value on textbox 1
and the second row value in txt box 2
and so on
can anyone advise how

cheers

andy
 
andy said:
hi i connect to a oracle database and i i do the
following select
select distinct(book)
from book_table
where trun(date)=trunc(sysdate-1)

it returns a column of with 3 rows in it
what i have is a form that has 3 text boxes on it
i want to put the first row value on textbox 1
and the second row value in txt box 2
and so on

If you have opened an ADO recordset named 'rs', then something like:

Form1.TextBox1.Text = rs!Book
rs.MoveNext
Form1.TextBox2.Text = rs!Book
rs.MoveNext
Form1.TextBox3.Text = rs!Book

Jamie.

--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top