0

Intro.

i have made a application in vs 2008 using c# and at back end i am using sql express 2005.

Application background:

just like report tool in which user select some parameters and get results in cube after she can import that result into excel or in any formats.

problem:

  1. user mostly processing 15 to 70 months report which takes 45 mints to 1.25 hours to
    complete but sometime result generated for 9 months and sometime 11 months not as
    selected months -- show alert: timeout....

  2. how to attach and deattach my database file when my software is installing
    (or after installation) as my application installer installs my apps.
    and sql express 2005

koopajah
  • 23,792
  • 9
  • 78
  • 104
Haid
  • 111
  • 2
  • 10

1 Answers1

0

Use sp_attach_db to attach a database to a SQL server: http://msdn.microsoft.com/en-us/library/ms179877.aspx

If you're connecting to the server using a SqlCommand object, then you can set the CommandTimeout to 0 for indefinite execution. That is not advised though! http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlcommand.commandtimeout.aspx

Steven K.
  • 2,097
  • 16
  • 15
  • i have already set CommandTimeout to 0 but no change it shows me same error. can you explain why my application not processing all the selected months and it is much slow. – Haid Dec 22 '10 at 06:51