Answer by RickD
Why are you removing the .ldf file? Do you realise that anything not written to the data file will be lost if you do this? Why are you detaching the database at the end of each seesion?If your...
View ArticleAnswer by mrdenny
Why are you attaching and detaching the database from the engine each time you open it? Attach it once and leave it attached.As for deleting the log file, stop doing that. You should NEVER delete the...
View ArticleAnswer by Wes Brown
I agree with the above post 100%Here is the code to do what you are asking. If it fails more than likely your database is in an inconsistent state and will will require work to attach and recover what...
View ArticleAnswer by Rajib Bahar
can you educate us on the consideration/benefit around this kind of attachment/detachment process? Are you trying to prevent this database appearing to other users due to security, confidentiality...
View Article
More Pages to Explore .....