VB.NET App can't retreive data from SQL DB after several hours and/or 1 day or more
Posted on 2008-01-30
We currently have a Database that is running on Windows 2003 Server that runs on a VMWare Server (most recent version of VMWare).
I have VS 2005 with .NET Framework 3.0 installed running on a XP Professional Dell Laptop w/ SP2 installed.
I have a front-end (vb.net) application I've created that connects to the DB. I'm running into an issue where I have to reboot the DB once a day to get my application to connect, query the db and return all the data from the tables to the ListViewItem control that displays all the data and a couple of other ComboBox controls that get populated.
I've got the sqlStr.ConnectionTimeout = 300 and the sqlCommand.CommandTimeout = 300 so that the application has enough time to connect, retrieve and load data to the app. It usually takes the application (on a good connection, i.e. right after a db reboot) about 2 minutes to load data and appear in front of the user. On a bad connection, it takes around 3 - 4 minutes for it to load. So, when it gets past the 2 minute mark, I know the db has to be rebooted.
What I can't figure out is, why won't the DB return my data to populate it in the application OR what in the application prevents the DB from returning the Data? As far as I can tell, everything works fine until after a day or who knows, several hours.
Thank you in advance,