Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 198
  • Last Modified:

Sorting DAO Tables in VB

Hi...
I've got an application developen in VB using DAO to open Access Database file. My problem is how to sort the record sets when thy are opened as a Table. Indexes can not be used in Table mode!
0
progex
Asked:
progex
  • 4
  • 2
1 Solution
 
DhaestCommented:
How do you assign your table to the dao-recordset ?
Otherwise you can give it a order by clause when you open your recordset:

rs.open "select * from yourTable order by YourField"
0
 
progexAuthor Commented:
well, i'm using the opendatabase function of the database object to open the recordset and set it to the record set object as follows:

set data_rs = data_db.opendatabase("database name", "table name, dbOpenTable)

no sorting option in here!!!
:(
0
 
progexAuthor Commented:
isn't there a method with the recordset object to reorder the table??
What about the sort methord of the recordset object???
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
DhaestCommented:
set data_rs = data_db.openrecordset("select * from tableName order by YourField", dbOpenDynaset)
0
 
DhaestCommented:
My recommandation: answered by Dhaest, because there was no reaction after my comment, so I guess that it the asker was satisfied about my comment.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now