Timeout in connection string

Discussion in 'ASP General' started by kant, Jun 16, 2005.

  1. kant

    kant Guest

    stringA= "Provider=SQLOLEDB.1;Persist Security Info=False;User
    ID=sa;PWD=password;Initial Catalog=DB;Data Source=127.0.0.1;Connect
    Timeout=30"

    stringB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
    Server.MapPath("DB.MDB") & ";Connect Timeout=30"


    Hi All,

    I have use the above connection string in an ASP application, stringA with
    SQL Server, it works!
    stringB with MS ACCESS, it doesnt works if I add the "connect timeout"
    parameter!!
    How can I solve it!? so that I can set the connection timeout when I using
    MSACCESS as Database
    (I dont want to use ODBC connection).

    Thx alot
     
    kant, Jun 16, 2005
    #1
    1. Advertising

  2. kant wrote:
    > stringA= "Provider=SQLOLEDB.1;Persist Security Info=False;User
    > ID=sa;PWD=password;Initial Catalog=DB;Data Source=127.0.0.1;Connect
    > Timeout=30"
    >
    > stringB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
    > Server.MapPath("DB.MDB") & ";Connect Timeout=30"
    >
    >
    > Hi All,
    >
    > I have use the above connection string in an ASP application, stringA
    > with SQL Server, it works!
    > stringB with MS ACCESS, it doesnt works if I add the "connect timeout"
    > parameter!!
    > How can I solve it!? so that I can set the connection timeout when I
    > using MSACCESS as Database
    > (I dont want to use ODBC connection).
    >

    What do you intend to gain by using that parameter. I'm not sure that
    parameter is supported by the Jet provider. You can set the property
    directly on the Connection object if you must have it:
    set cn=createobject("adodb.connection")
    cn.CommandTimeout=30

    With an Access database, I really don't see what is being gained by the use
    of this property.
    Bob Barrows
    --
    Microsoft MVP -- ASP/ASP.NET
    Please reply to the newsgroup. The email account listed in my From
    header is my spam trap, so I don't check it very often. You will get a
    quicker response by posting to the newsgroup.
     
    Bob Barrows [MVP], Jun 16, 2005
    #2
    1. Advertising

  3. kant

    Kant Guest

    Hi Bob,

    I found the error happened in IIS setting but not DB connection timeout,
    here is the error message, what should I modify the Server.scripttimeout !?
    Thx


    Error Type:
    Active Server Pages, ASP 0113 (0x80004005)
    The maximum amount of time for a script to execute was exceeded. You can
    change this limit by

    specifying a new value for the property Server.ScriptTimeout or by changing
    the value in the IIS administration tools.


    "Bob Barrows [MVP]" wrote:

    > kant wrote:
    > > stringA= "Provider=SQLOLEDB.1;Persist Security Info=False;User
    > > ID=sa;PWD=password;Initial Catalog=DB;Data Source=127.0.0.1;Connect
    > > Timeout=30"
    > >
    > > stringB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
    > > Server.MapPath("DB.MDB") & ";Connect Timeout=30"
    > >
    > >
    > > Hi All,
    > >
    > > I have use the above connection string in an ASP application, stringA
    > > with SQL Server, it works!
    > > stringB with MS ACCESS, it doesnt works if I add the "connect timeout"
    > > parameter!!
    > > How can I solve it!? so that I can set the connection timeout when I
    > > using MSACCESS as Database
    > > (I dont want to use ODBC connection).
    > >

    > What do you intend to gain by using that parameter. I'm not sure that
    > parameter is supported by the Jet provider. You can set the property
    > directly on the Connection object if you must have it:
    > set cn=createobject("adodb.connection")
    > cn.CommandTimeout=30
    >
    > With an Access database, I really don't see what is being gained by the use
    > of this property.
    > Bob Barrows
    > --
    > Microsoft MVP -- ASP/ASP.NET
    > Please reply to the newsgroup. The email account listed in my From
    > header is my spam trap, so I don't check it very often. You will get a
    > quicker response by posting to the newsgroup.
    >
    >
    >
     
    Kant, Jun 17, 2005
    #3
  4. kant

    Kant Guest

    fixed...just click ths IIS setting menu, so silly....thx and pls ignore this
    question.

    "Kant" wrote:

    > Hi Bob,
    >
    > I found the error happened in IIS setting but not DB connection timeout,
    > here is the error message, what should I modify the Server.scripttimeout !?
    > Thx
    >
    >
    > Error Type:
    > Active Server Pages, ASP 0113 (0x80004005)
    > The maximum amount of time for a script to execute was exceeded. You can
    > change this limit by
    >
    > specifying a new value for the property Server.ScriptTimeout or by changing
    > the value in the IIS administration tools.
    >
    >
    > "Bob Barrows [MVP]" wrote:
    >
    > > kant wrote:
    > > > stringA= "Provider=SQLOLEDB.1;Persist Security Info=False;User
    > > > ID=sa;PWD=password;Initial Catalog=DB;Data Source=127.0.0.1;Connect
    > > > Timeout=30"
    > > >
    > > > stringB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
    > > > Server.MapPath("DB.MDB") & ";Connect Timeout=30"
    > > >
    > > >
    > > > Hi All,
    > > >
    > > > I have use the above connection string in an ASP application, stringA
    > > > with SQL Server, it works!
    > > > stringB with MS ACCESS, it doesnt works if I add the "connect timeout"
    > > > parameter!!
    > > > How can I solve it!? so that I can set the connection timeout when I
    > > > using MSACCESS as Database
    > > > (I dont want to use ODBC connection).
    > > >

    > > What do you intend to gain by using that parameter. I'm not sure that
    > > parameter is supported by the Jet provider. You can set the property
    > > directly on the Connection object if you must have it:
    > > set cn=createobject("adodb.connection")
    > > cn.CommandTimeout=30
    > >
    > > With an Access database, I really don't see what is being gained by the use
    > > of this property.
    > > Bob Barrows
    > > --
    > > Microsoft MVP -- ASP/ASP.NET
    > > Please reply to the newsgroup. The email account listed in my From
    > > header is my spam trap, so I don't check it very often. You will get a
    > > quicker response by posting to the newsgroup.
    > >
    > >
    > >
     
    Kant, Jun 17, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Guoqi Zheng
    Replies:
    4
    Views:
    13,123
    Guoqi Zheng
    Jun 3, 2004
  2. Replies:
    3
    Views:
    864
    Samuel R. Neff
    Aug 3, 2007
  3. Wei  Lu
    Replies:
    2
    Views:
    6,019
    Wei Lu
    Feb 16, 2009
  4. shmuel witman

    Connection timeout (connection closing after 100 sec )

    shmuel witman, Dec 4, 2005, in forum: ASP .Net Web Services
    Replies:
    2
    Views:
    917
    shmuel witman
    Dec 6, 2005
  5. Mark Probert

    Timeout::timeout and Socket timeout

    Mark Probert, Oct 6, 2004, in forum: Ruby
    Replies:
    1
    Views:
    1,355
    Brian Candler
    Oct 6, 2004
Loading...

Share This Page