User Profile

Collapse

Profile Sidebar

Collapse
pghquest
pghquest
Last Activity: Nov 20 '14, 05:57 PM
Joined: Nov 18 '14
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • pghquest
    replied to SQL pass thru VBA / ODBC timeout
    I changed the regedit and its running again.. not my ideal solution though..
    See more | Go to post

    Leave a comment:


  • pghquest
    replied to SQL pass thru VBA / ODBC timeout
    Currently have the following. Its timing out doing the select count. If I copy/paste the code into SQL it works fine, but it takes time. The tables are huge.. Hundred million + records..

    Code:
    Public Function GetQueryCount7C() As Long
    CurrentDb.QueryTimeout = 0
        Dim rst As DAO.Recordset
        Dim sql As String
        sql = "SELECT     COUNT(*) / 2500 + 1 AS total " _
            & "FROM
    ...
    See more | Go to post
    Last edited by Rabbit; Nov 20 '14, 06:32 PM. Reason: Please use [code] and [/code] tags when posting code or formatted data. Second warning

    Leave a comment:


  • pghquest
    replied to SQL pass thru VBA / ODBC timeout
    I'm getting a "2" in the Immediate window..
    See more | Go to post

    Leave a comment:


  • pghquest
    replied to SQL pass thru VBA / ODBC timeout
    Thanks for the response. Still receiving the following
    Error 3146 ODBC - call failed.

    I dont know what you mean by AND's and OR's

    I wrote that part in SQL and then copied it and modified it for VBA
    See more | Go to post

    Leave a comment:


  • pghquest
    started a topic SQL pass thru VBA / ODBC timeout

    SQL pass thru VBA / ODBC timeout

    I have the following count taking place in my Access VBA code. Sometimes it works, and sometimes it doesnt. Seems the timeout is at 60 and I cant figure out how to change it to 600.

    If it errors I'm getting a 3146 ODBC - call failed error

    Code:
    Public Function GetQueryCount7C() As Long
    CurrentDb.QueryTimeout = 0
        Dim rst As DAO.Recordset
        Dim sql As String
        
        sql = "SELECT
    ...
    See more | Go to post
    Last edited by Rabbit; Nov 18 '14, 04:20 PM. Reason: Please use [code] and [/code] tags when posting code or formatted data.
No activity results to display
Show More
Working...