Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8139057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T11:42:00+00:00 2026-06-06T11:42:00+00:00

I use odbc to interface mysql. I start odbc by the following code: ConnectString

  • 0

I use odbc to interface mysql. I start odbc by the following code:

ConnectString = "Driver={MySQL ODBC 5.1 Driver};Server=localhost;Database=mydb; User=userdb;Password=pwddb;Option=3;",case odbc:connect(ConnectString, [{scrollable_cursors,off}]) of ...    

After 8 hours of inactivity (more or less), odbc crashs:

=CRASH REPORT==== 22-Jun-2012::02:09:27 ===   crasher:
    initial call: odbc:init/1
    pid: <0.113.0>
    registered_name: []
    exception exit: {stopped,{'EXIT',<0.108.0>,killed}}
      in function  gen_server:terminate/6 (gen_server.erl, line 737)
    ancestors: [odbc_sup,<0.111.0>]
    messages: [{'EXIT',#Port<0.967>,normal}]
    links: [<0.112.0>]
    dictionary: []
    trap_exit: true
    status: running
    heap_size: 377
    stack_size: 24
    reductions: 2237   neighbours:

Is a connection limited in the time ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T11:42:01+00:00Added an answer on June 6, 2026 at 11:42 am

    Mysql has a variable wait_timeout that controls how long the server will wait for a client to do something. The default value is 28800 secs. Casually, 28800 secs are 8 hours, so you might want to check that in your server configuration and set it to a larger value.

    Other than that, you should let your worker terminate, and have the supervisor restart it as normal. Or (if using a gen_server or gen_fsm) setup a timeout to issue a query or a ping to keep alive the connection every hour or so, to keep the worker alive.

    Best!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Driver={MySQL ODBC 5.1 Driver};Server=192.168.1.103;Database=mysql;User=root; Password=;Option=3; It works just fine when use localhost or 127.0.0.1,
I'm trying to use odbc to connect some erlang code to a mysql server.
I'm using MySQL ODBC 5.1 driver under Windows to connect to my database. In
I've been writing a multi-threaded DLL for database access using ADO/ODBC for use with
I know PHP and am just beginning with MySql (but plan to use ODBC).
I want to use ADO via ODBC to pull records from a database table
i am making a wrapper for my use for database, using Poco::Database::ODBC the normal
I'm trying to use Perl ODBC to connect to a Microsoft SQL server. My
I need to access a mysql database from c# code but I would prefer
We have some legacy applications that use an ODBC driver for accessing their databases.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.