I use Access & DAO all the time in my projects. First you have to Open the database and open the recordset.

Set dbY = OpenDatabase("c:\dma\data\TM_YCode.mdb")
Set rsY = dbY.OpenRecordset("YCodes")

The YCodes in OpenRecordset can refer to a table or a query. You can also define your recordset with SQL.

Set rsL = dbL.OpenRecordset("SELECT HCPRAL.ClaimNum, HCPRAL.CPTCode From HCPRAL ORDER BY HCPRAL.ClaimNum;")

If you are planning a lookup, make sure that you have an index on the field you are looking up and that you set the index before you perform the seek or the findfirst. The syntax can be a little tricky as you have to send a quoted string within another string.

example: rsL.FindFirst "ClaimNum = '" & ClaimNo & "'"

The seek is faster and the syntax is a little easier but you have to make sure that you have the index defined in the database and set the index before you do the seek.

rsArchive.Index = "SYNC"      'Set correct Index
rsArchive.Seek "=", SyncNbr   'Seek Method using Index

If you have problems give me a call.

[EMAIL PROTECTED] wrote:

Hi All,

I will be working of a script to enter ED Billing into my MT C/S Abs
Module, and will be getting a file from a coding service.

That file will need to have some crosswalk done on some of the codes that
are sent, has anyone out there opend an Access db via DAO to do lookups and
crosswalks ?

Are there any known issues around it ?


Thanks


Bruce







-- Neil Carman Director Technical Development Manigault & Associates LLC

http://www.m-allc.com
Work: (805) 680-5601
Fax:  (714) 968-5632




Reply via email to