Re: Help sending sql into ORACLE



On 1 Jul 2005 07:25:41 -0700, "Max" <max.atwood@xxxxxxxxxxxxxxxx> wrote:

>I am using ADO. Can you give an example of how the execute command in
>ADO works? Also, I understand there is (somewhere in the world) an ADO
>help file (ADO280.chm???). I am looking for a source to download that
>from so I can do more research. Do you know where I might find it?

The file is "mdacxml.chm".

It comes with the download the Microsoft SQL Server 2000 "Books Online"
reference chm.

<quote>
3.2.1 Link to MDAC and XML Documentation Does Not Work

When SQL Server Books Online is opened using F1 or the Help menu
in an MMC snap-in (such as SQL Server Enterprise Manager), the
link to the MDAC and XML documentation does not work. To view
the MDAC and XML documentation, open Mdacxml.chm located in
C:\Program Files\Microsoft Sql Server\80\Tools\Books.

NOTE: The link works correctly when SQL Server Books Online
is started directly from the SQL Server Program Group on the
Start menu, or from running Sql80.col.
</quote>

..:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:

<code license="GPL 2.0+">
Public Function ADO_GetDatabaseName(cn As ADODB.Connection) As String
' Purpose: To determine the name of the current database that a connection is
using.
' Assumes: Using MS SQL 7.0+
' 2003-Feb-28 1500 [Michael B. Johnson]
Dim sDatabaseName As String
Dim rs As ADODB.Recordset
Dim sSQL As String

sSQL = "SELECT DB_NAME()"
If cn.State = adStateOpen Then
Set rs = cn.Execute(sSQL)
On Error Resume Next
ADO_GetDatabaseName = rs.Fields(0).Value
End If

ExitThis:
Call ADO_FreeRecordset(rs)
End Function
</code>
_______________________
Michael B. Johnson
.



Relevant Pages

  • RE: How to populate VBA Variables from ADODB.Connection Results?
    ... y As Integer 'Incremental counters to populate ... 'Find SQL Server data for the active user. ... "GetUserNameA" (ByVal lpBuffer As String, ... Dim UserName As String ...
    (microsoft.public.excel.programming)
  • Error Trap Connection to SQL server
    ... I am trying to establish links from Ms Access to tables in a SQL server ... the database is attached ... Dim rs1 As DAO.Recordset ... Dim strLinkName As String ...
    (microsoft.public.access.security)
  • Help with Error Trapping Connection to SQL server
    ... I am trying to establish links from Ms Access to tables in a SQL server ... the database is attached ... Dim rs1 As DAO.Recordset ... Dim strLinkName As String ...
    (microsoft.public.access.modulesdaovba)
  • Re: using VBA to insert records from access database to sql server
    ... Brendan and Tim, ... insert records from Access table to SQL server table with one error which I ... Dim oConn As ADODB.Connection ... Dim strInsert As String ...
    (microsoft.public.access.modulesdaovba)
  • VBA ConnectionTimeout problems
    ... Server is MS SQL Server 2000 ... Dim connDB As New ADODB.Connection 'connection to SQL Server ... Dim strTimeDay As String ...
    (microsoft.public.excel.programming)