Change timeout for mssql queries ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Lars Nielsen

    Change timeout for mssql queries ?

    I'm trying to execute a long query with mssql_query(), but it fails after 30 seconds.

    I've tried to use ini_set in my script :
    ini_set("mssql. timeout", "120");
    Both just before the query and before the connection is initiated.

    I've tried to add this to php.ini :
    mssql.timeout = 120

    But nothing seems to work, mssql_query() in the script still fails after precisely 30 seconds.

    Please advise.

    --
    Best regards
    Lars V. Nielsen
    Denmark




  • KAH

    #2
    Re: Change timeout for mssql queries ?

    "Lars Nielsen" <lars.nielsen@g et2net.dk> wrote in
    news:3f39fbcb$0 $32460$edfadb0f @dread16.news.t ele.dk:
    [color=blue]
    > I'm trying to execute a long query with mssql_query(), but it fails
    > after 30 seconds.
    >
    > I've tried to use ini_set in my script :
    > ini_set("mssql. timeout", "120");
    > Both just before the query and before the connection is initiated.
    >
    > I've tried to add this to php.ini :
    > mssql.timeout = 120
    >
    > But nothing seems to work, mssql_query() in the script still fails
    > after precisely 30 seconds.[/color]

    Sounds like you're actually encountering the script runtime timeout. Try
    set_time_limit (120);

    KAH

    Comment

    • Lars Nielsen

      #3
      Re: Change timeout for mssql queries ?

      Does this mean that there aren't any specific timeout setting for mssql ?

      Is the "mssql.time out" actually setting not used at all ?

      Best regards
      Lars V. Nielsen

      "KAH" <kah@kahnews.cj b.net> wrote in message news:Xns93D6906 E1D9C6kahatkahn ewsdotcjbdo@193 .213.112.19...[color=blue]
      > "Lars Nielsen" <lars.nielsen@g et2net.dk> wrote in
      > news:3f39fbcb$0 $32460$edfadb0f @dread16.news.t ele.dk:
      >[color=green]
      > > I'm trying to execute a long query with mssql_query(), but it fails
      > > after 30 seconds.
      > >
      > > I've tried to use ini_set in my script :
      > > ini_set("mssql. timeout", "120");
      > > Both just before the query and before the connection is initiated.
      > >
      > > I've tried to add this to php.ini :
      > > mssql.timeout = 120
      > >
      > > But nothing seems to work, mssql_query() in the script still fails
      > > after precisely 30 seconds.[/color]
      >
      > Sounds like you're actually encountering the script runtime timeout. Try
      > set_time_limit (120);
      >
      > KAH[/color]


      Comment

      • KAH

        #4
        Re: Change timeout for mssql queries ?

        "Lars Nielsen" <lars.nielsen@g et2net.dk> wrote in
        news:3f3d4a22$0 $32539$edfadb0f @dread16.news.t ele.dk:
        [color=blue]
        > Does this mean that there aren't any specific timeout setting for
        > mssql ?
        >
        > Is the "mssql.time out" actually setting not used at all ?[/color]

        Probably used for either the connection, or something like that. Check the
        manual. The runtime timeout will override other settings anyway.

        KAH

        Comment

        Working...