Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
None of that seems relevant to me. You are using ADO to pass a command to
the database, not MSQuery, so it is what the database can do that is relevant. The joins etc. are all handled by the DB engine. Excel doesn't come into it, Access is totally irrelevant. -- --- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Arvi Laanemets" wrote in message ... Hi Thanks! I think I have to try to modify your code somehow, so I can use a pass-through there. 1. I have checked before, and found, that average simple Access/Excel query (Select * from Table) from most tables in our Sybase database takes about 20 minutes, and only seconds from Sybase Anywhere. 2. It isn't very good idea to meddle with MS query in any critical database, when there are 100 - 200 users connected to it. 3. The original (Sybase) query uses some functions not available in Access or Excel. Replacing them is probably possible, but may cause additional problems. 4. The query uses 4 Left Outer Join's (1 join + 3 join's sequently) + 4 Left Outer Join's in second part (it is an Union query). Unless I missed something, in Excel2000 only 2 tables can be connected using outer join's. -- Arvi Laanemets ( My real mail address: arvi.laanemets<attarkon.ee ) "Bob Phillips" wrote in message ... Simple using ADO. Sub GetData() Const adOpenForwardOnly As Long = 0 Const adLockReadOnly As Long = 1 Const adCmdText As Long = 1 Dim oRS As Object Dim sConnect As String Dim sSQL As String Dim ary sConnect = "Provider=Sybase.ASEOLEDBProvider;" & _ "Srvr=myASEServer,5000;" & _ "Catalog=myDBName;" & _ "User Id=myUserName;" & _ "Password=myUserPassword" sSQL = "SELECT * From TableName" Set oRS = CreateObject("ADODB.Recordset") oRS.Open sSQL, sConnect, adOpenForwardOnly, _ adLockReadOnly, adCmdText ' Check to make sure we received data. Worksheets("Sheet1").Range("A1").CopyFromRecordset oRS oRS.Close Set oRS = Nothing End Sub But see http://www.carlprothman.net/Default....rverEnterprise for some notes. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
pass an excel cell value to a web query | Excel Programming | |||
Pass parametres from Excel to Access query | Excel Programming | |||
Is there a way to pass parameters to a web query in excel | Excel Programming | |||
How to pass a date in Excel to ms query | Excel Programming | |||
How to pass a date in Excel to ms query | Excel Programming |