Our app uses third party component and we do not have source code.
That component requires as parameter Connection object only and we do not
have access to the Command object it creates inside. So if query it
generates exceeds 30 seconds timeout exception occurs.

Is it possible to set CommandTimeout at connection level? May be there is
undocumented ConnectionString options?
I can`t find it in MSDN.
Please help
Thanks in adv
Serg

RE: Is it possible to set CommandTimeout at connection level? by SaravananKV

SaravananKV
Fri Mar 11 04:31:03 CST 2005

Hi,

For SqlConnection, you can specify "Connection Timeout=n" in the connection
string

Saravanan K V

"Serg" wrote:

> Our app uses third party component and we do not have source code.
> That component requires as parameter Connection object only and we do not
> have access to the Command object it creates inside. So if query it
> generates exceeds 30 seconds timeout exception occurs.
>
> Is it possible to set CommandTimeout at connection level? May be there is
> undocumented ConnectionString options?
> I can`t find it in MSDN.
> Please help
> Thanks in adv
> Serg
>
>
>

Re: Is it possible to set CommandTimeout at connection level? by Serg

Serg
Fri Mar 11 04:39:07 CST 2005

Thanks for fast reply.
But this is not the solution.
ConnectionTimeout does not the same as CommandTimeout.
ConnectionTimeout affects only at Connection stage when client searches net
for SqlServer.
If i set ConnectionTimeout it does not affect on CommandTimeout. It remains
default 30 sec.



"Saravanan K V" <SaravananKV@discussions.microsoft.com> wrote in message
news:7DB226EE-B500-47D5-AA4E-8903F05DFEC2@microsoft.com...
> Hi,
>
> For SqlConnection, you can specify "Connection Timeout=n" in the
connection
> string
>
> Saravanan K V
>
> "Serg" wrote:
>
> > Our app uses third party component and we do not have source code.
> > That component requires as parameter Connection object only and we do
not
> > have access to the Command object it creates inside. So if query it
> > generates exceeds 30 seconds timeout exception occurs.
> >
> > Is it possible to set CommandTimeout at connection level? May be there
is
> > undocumented ConnectionString options?
> > I can`t find it in MSDN.
> > Please help
> > Thanks in adv
> > Serg
> >
> >
> >



Re: Is it possible to set CommandTimeout at connection level? by Cor

Cor
Fri Mar 11 05:12:19 CST 2005

Serg,

Did you try it?

Cor



Re: Is it possible to set CommandTimeout at connection level? by Marina

Marina
Fri Mar 11 10:38:38 CST 2005

No, you cannot.

You should talk to the 3rd party regarding giving you a way to specify the
command timeout. Like adding a paramter to their method to let you control
that.

"Serg" <sergNOSPAM@alef.ru> wrote in message
news:%23AiqSBiJFHA.3928@TK2MSFTNGP09.phx.gbl...
> Our app uses third party component and we do not have source code.
> That component requires as parameter Connection object only and we do not
> have access to the Command object it creates inside. So if query it
> generates exceeds 30 seconds timeout exception occurs.
>
> Is it possible to set CommandTimeout at connection level? May be there is
> undocumented ConnectionString options?
> I can`t find it in MSDN.
> Please help
> Thanks in adv
> Serg
>
>



Re: Is it possible to set CommandTimeout at connection level? by Serg

Serg
Mon Mar 14 04:27:50 CST 2005

Yes I did.
ConnectionTimeout does not affect on CommandTimeout

"Cor Ligthert" <notmyfirstname@planet.nl> wrote in message
news:uKxLpsiJFHA.2560@TK2MSFTNGP09.phx.gbl...
> Serg,
>
> Did you try it?
>
> Cor
>
>



Re: Is it possible to set CommandTimeout at connection level? by Cor

Cor
Mon Mar 14 04:34:07 CST 2005

Serg,

Than you have in my opinion a problem for what only your vendor of the 3th
party commandcontrol can help you with.

Cor