Wednesday, March 28, 2012
Problems in attaching db
Does anyone know why trying to attach a db (.mdf and .ldf files) to a new db, the "Attach database" item in the menu is disabled, please? do I have to reinstall SQL Server?
You could try to attach your db with a t-sql statement.
sp_attach_db @.dbname = 'db name',
@.filename1 = 'path_to/file.mdf' ,
@.filename2 = 'path_to/file.ldf'|||I entered the following in the Query Analyzer and got the result shown:
EXEC sp_attach_db @.dbname = N'AARETAIL',
@.filename1 = N'C:\MSSQL7\Data\AARETAIL_Data.MDF',
@.filename2 = N'C:\MSSQL7\Data\AARETAIL_Log.LDF'
Server: Msg 5172, Level 16, State 15, Line 1
The header for file 'C:\MSSQL7\Data\AARETAIL_Log.LDF' is not a valid database file header. The PageAudit property is incorrect.
I can find nothing about PageAudit property.
What is it and how do I need to modify the command?
Many thanks!|||Originally posted by atorlone
I entered the following in the Query Analyzer and got the result shown:
EXEC sp_attach_db @.dbname = N'AARETAIL',
@.filename1 = N'C:\MSSQL7\Data\AARETAIL_Data.MDF',
@.filename2 = N'C:\MSSQL7\Data\AARETAIL_Log.LDF'
Server: Msg 5172, Level 16, State 15, Line 1
The header for file 'C:\MSSQL7\Data\AARETAIL_Log.LDF' is not a valid database file header. The PageAudit property is incorrect.
I can find nothing about PageAudit property.
What is it and how do I need to modify the command?
Many thanks!
Do you run MsSql 7 or 2000 ?|||Originally posted by atorlone
I entered the following in the Query Analyzer and got the result shown:
EXEC sp_attach_db @.dbname = N'AARETAIL',
@.filename1 = N'C:\MSSQL7\Data\AARETAIL_Data.MDF',
@.filename2 = N'C:\MSSQL7\Data\AARETAIL_Log.LDF'
Server: Msg 5172, Level 16, State 15, Line 1
The header for file 'C:\MSSQL7\Data\AARETAIL_Log.LDF' is not a valid database file header. The PageAudit property is incorrect.
I can find nothing about PageAudit property.
What is it and how do I need to modify the command?
Many thanks!
try attaching the database without the logfile:
EXEC sp_attach_db @.dbname = N'AARETAIL',
@.filename1 = N'C:\MSSQL7\Data\AARETAIL_Data.MDF'
Wednesday, March 21, 2012
problems connecting to sql express 2005 server, where mdf file go?
"Data Source=CTS\SQLEXPRESS;Initial Catalog=UpdateAttributes;Integrated Security=True"
My program will only work if there is a local copy of MDF database located within my application directory. If I remove the local copy, it errors "No process is on the other end of the pipe" Is it possible to have my application without the local copy of the MDF? I thought the idea is to have the MDF on the server. Then my app would not have the MDF copy!?Fixed the problem. Went to the server, changed the sql server 2005 surface area configuration under remote connections from using TCP/IP to TCP/IP and named pipes.
problems connecting to DB.
Hi,
thats what i get when running the app:
Server Error in '/Jobs5' Application.
Unable to open the physical file "C:\MPDB\ManPower.mdf". Operating system error 32: "32(The process cannot access the file because it is being used by another process.)".
An attempt to attach an auto-named database for file C:\MPDB\ManPower.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
Nothing seems to be using that file. So what is the problem?
Thanks.
The problem is that the DB is being used by the default web server of VS2005 whule i am trying to access using IIS.
the qu. is how do i make my application use IIS insted?
Thanks.