Jump to content

Check out our Community Blogs

Register and join over 40,000 other developers!

Recent Status Updates

View All Updates

- - - - -

Retrieve data from different database using ADOBE.recordset


  • Please log in to reply
No replies to this topic

#1 nodeffect


    CC Lurker

  • Just Joined
  • Pip
  • 2 posts

Posted 24 June 2010 - 06:06 PM

Hi guys,
I'm having some problems linking two database together.

Below is my partial code example,

strConInter = .......some codes
dbsInter = New ADODB.connection

dbsExample = New ADODB.connection

rstCustExpListTemp = New ADODB.Recordset
                        rstCustExpListTemp.Open("SELECT ARCUSFIL_SQL.slspsn_no, ARSLMFIL_SQL.slspsn_name, ARCUSFIL_SQL.cus_no, ARCUSFIL_SQL.cus_name, ARCUSFIL_SQL.zip AS CustomerExpiry " _
                                & "FROM ARCUSFIL_SQL INNER JOIN ARSLMFIL_SQL ON ARCUSFIL_SQL.slspsn_no = ARSLMFIL_SQL.slspsn_no " _
                                & "WHERE cus_no = '" & x & "' ORDER BY ARCUSFIL_SQL.slspsn_no, ARCUSFIL_SQL.cus_no;", dbsInter, CursorTypeEnum.adOpenStatic, LockTypeEnum.adLockOptimistic)

                        da.Fill(ds, rstCustExpListTemp, "ImportCustExpList")

so my question is I want to open dbsExample also together with dbsInter. But I can't put like "dbsInter, dbsExample, CursorTypeEnum.adOpenStatic, LockTypeEnum.adLockOptimistic)"

Need help, thanks
  • 0

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download