Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2002
    Posts
    2

    Unanswered: type mismatch erroer from a query from VB

    A runtime error 13, "Type Mismatch" is generated from the recordset creation query. What is causing this error and what needs correcting.

    Dim rs As Recordset ' Open Data Table
    strSQL = "SELECT TAG_NO From [SCR - DATABASE] WHERE [I/O]=True AND INSTR=True"
    Debug.Print strSQL 'Checks syntax of SQL Statement
    Set rs = dbCHSP.OpenRecordset(strSQL)'Create a recordset

    Any help would be appreciated

  2. #2
    Join Date
    Jan 2002
    Location
    At the Edge of America!
    Posts
    55
    Are you sure that you I/O and your Instr are yes no datatypes?

  3. #3
    Join Date
    Jan 2004
    Posts
    5

    Angry type mismatch erroer from a query from VB

    I have this problem as well I use mssql2000 and try to connect DB by
    dim cnn As ADODB.Connection
    dim rec As Recordset

    Set cnn = New ADODB.Connection
    cnn.Open "Provider=SQLOLEDB;Password=123if;User ID=sa;Initial Catalog=CustomerService;Data Source=SIAM-INT-SERV"

    ....the databse and connection is success and without error
    but after then i wanna query by

    Set rec = cnn.Execute("SELECT UsrNme, Passwd ,permission FROM Username where UsrNme = 'rud'")

    A runtime error 13, "Type Mismatch" is generated from the recordset creation query. I can use this code in win2000 but it's error 13 "type mismatch" in win98 ?????????I kinda confuse now...please help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •