Microsoft KB Archive/140702

From BetaArchive Wiki
Knowledge Base


PSS ID Number: 140702

Article Last Modified on 10/20/2000



The information in this article applies to:

  • Microsoft Excel for Windows 95 7.0



This article was previously published under Q140702


SUMMARY

In Data Access Object (DAO) Reference Help, the "Using SQL PassThrough with DAO" topic contains an incorrect code example under the "To create and execute an SQL pass through query from code" heading.

MORE INFORMATION

The incorrect code example reads:

   Set dbs = OpenDatabase("Salary.mdb" _
        dbs.Connect = "ODBC;dsn=Accounting;uid=Dagny;"& _
        pwd=Bandit;database=Payroll;"
   dbs.Execute "Update UPDATE Employees SET Salary = Salary * 1.1;", _
        dbSQLPassThrough
                

The correct syntax for this example is shown below:

   Set dbs = OpenDatabase("Salary.mdb")
   dbs.Connect = "ODBC;dsn=Accounting;uid=Dagny;" & _
        "pwd=Bandit;database=Payroll;"
   dbs.Execute "UPDATE Employees SET Salary = Salary * 1.1;", _
        dbSQLPassThrough
                

STATUS

REFERENCES

For more information about Using SQL PassThrough With DAO, choose the Index tab in Help and type:

sql, pass-through queries


Keywords: KB140702
Technology: kbExcel95 kbExcel95Search kbExcelSearch kbExcelWinSearch