| |

VerySource

 Forgot password?
 Register
Search
View: 652|Reply: 4

Help. See what's wrong!

[Copy link]

1

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-1-27 10:00:01
| Show all posts |Read mode
I wrote a vb program. The database is sqlserver. After running for a while, I get the following error:

Run-time error '-2147217871 (80040e31)'
[Microsoft] [ODBC SQL Server Diver] Timeout has expired

What are the reasons for the above error?
Reply

Use magic Report

0

Threads

46

Posts

23.00

Credits

Newbie

Rank: 1

Credits
23.00

 China

Post time: 2020-2-20 20:30:01
| Show all posts
Try it with OleDB driver
Reply

Use magic Report

0

Threads

6

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-2-21 18:15:01
| Show all posts
conn..CommandTimeout = 0
Reply

Use magic Report

0

Threads

21

Posts

15.00

Credits

Newbie

Rank: 1

Credits
15.00

 China

Post time: 2020-3-1 22:00:01
| Show all posts
"After running for a while, the following error occurred"
It is estimated that the connection timed out, or the communication with the host has not been disconnected by the SQL server for a long time.
1 timeout is used upstairs: conn..CommandTimeout = 0
2The easiest is to set a clock to connect after a period of time
Reply

Use magic Report

0

Threads

4

Posts

4.00

Credits

Newbie

Rank: 1

Credits
4.00

 China

Post time: 2020-3-4 13:00:01
| Show all posts
There may be concurrent processing and cause timeout
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list