Wednesday, March 7, 2012
Can't read from database ?
one of our customers had a server crash. So I recovered the database from
backup and integrated it successfully into another sql server. I'm able to
connect through DSN file. Tests ok but the application which should work wit
h
the database seems to have problems to read or connect to the database.
What have I to bear in mind when recovering a database from backup on a new
server?
Sincerely
makOne of the first things is to ensure you have proper Login to User mapping.
You also may need to worry about some permissions. Have a look at these:
http://vyaskn.tripod.com/moving_sql_server.htm Moving DBs
http://msdn2.microsoft.com/en-us/library/ms345408(en-US,SQL.90).aspx Moving
system dbs 2005
http://www.databasejournal.com/feat...cle.php/3379901 Moving
system DB's 2000
http://www.support.microsoft.com/?id=314546 Moving DB's between Servers
http://www.support.microsoft.com/?id=224071 Moving SQL Server Databases
to a New Location with Detach/Attach
http://www.support.microsoft.com/?id=221465 Using WITH MOVE in a Restore
http://www.sqlservercentral.com/col...se
s.asp
Moving Users
http://www.support.microsoft.com/?id=246133 How To Transfer Logins and
Passwords Between SQL Servers
http://www.support.microsoft.com/?id=298897 Mapping Logins & SIDs after
a Restore
http://www.dbmaint.com/SyncSqlLogins.asp Utility to map logins to
users
http://www.support.microsoft.com/?id=168001 User Logon and/or Permission
Errors After Restoring Dump
http://www.support.microsoft.com/?id=240872 How to Resolve Permission
Issues When a Database Is Moved Between SQL Servers
http://www.sqlservercentral.com/scr...sp?scriptid=599
Restoring a .mdf
http://www.support.microsoft.com/?id=307775 Disaster Recovery Articles
for SQL Server
http://www.support.microsoft.com/?id=320125 Moving a Diagram
http://www.support.microsoft.com/?id=274463 Copy DB Wizard issues 2000
http://www.sqlservercentral.com/scr...utions/1598.asp Script
Roles and Permissions
Andrew J. Kelly SQL MVP
"K-iS" <KiS@.discussions.microsoft.com> wrote in message
news:A1A76593-8903-4C6E-8B69-464524359F8D@.microsoft.com...
> Hi,
> one of our customers had a server crash. So I recovered the database from
> backup and integrated it successfully into another sql server. I'm able to
> connect through DSN file. Tests ok but the application which should work
> with
> the database seems to have problems to read or connect to the database.
> What have I to bear in mind when recovering a database from backup on a
> new
> server?
> Sincerely
> mak
>|||Does the server have the same name? If not, has the application connection
string been changed to the new server?
Arnie Rowland, Ph.D.
Westwood Consulting, Inc
Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous
"K-iS" <KiS@.discussions.microsoft.com> wrote in message
news:A1A76593-8903-4C6E-8B69-464524359F8D@.microsoft.com...
> Hi,
> one of our customers had a server crash. So I recovered the database from
> backup and integrated it successfully into another sql server. I'm able to
> connect through DSN file. Tests ok but the application which should work
> with
> the database seems to have problems to read or connect to the database.
> What have I to bear in mind when recovering a database from backup on a
> new
> server?
> Sincerely
> mak
>
Friday, February 24, 2012
cant login to Microsoft SQL Web Data Administrator with sql option
at first i login using Windows Integrated option and created an account for sql login.
but when i tried to login using newly created account i get the following error.
Invalid username and/or password, you are using a windows login that is not your own, or server does not exist.
i am using XP SP2.Is MSDE on the same machine as Microsoft SQL Web Data Administrator?|||yes, they are on the same machine.|||Is your MSDE set up to use Mixed Mode?
By default, it will use Windows Authentication. You would have had to change this default when you installed MSDE, or after installation, through manually updating a registry setting (see this KB article:MSDE security and authentication).
You should be able to use Windows Authentication pretty readily since you are working off of your local machine.
Sunday, February 19, 2012
cant login my database
hi,
this is the connection string i am using
'Data Source=.\SQLEXPRESS;INITIAL CATALOG=;AttachDbFilename='|DataDirectory|\HotStage.mdf';Integrated Security=True;User Instance=True '
it works all right when working in debug mode, but after i deploy it to my XP's IIS, i can't login my database, the error message is
'Can not open user default database. Login failed. Login failed for user xxx\ASPNET' 'xxx' is my computer name
i am the Admin. of my computer.
could anybody help ? thx!!!
When running in debug mode, I'd guess that you're using the VS development web server, which runs under your user credentials. Consequently, because you're an admin it is allowed to access SQL Server.
When hosting it in IIS, the worker process is running under the ASPNET user account, and this will not be allowed to access SQL Server by default. Therefore, using SQL Server Management Studio, create a login for the ASPNET account on the SQL Server and then grant it access to the appropriate databases.
|||hi,
of course my SQL Server has ASPNET account, and it has the permission to 'connect sql' and 'create any database', but i still connect to my SQL.
i read some posts somewhere else, and they said i should remove the 'User Instance=True' clause, and i did connected to my SQL, but now i have another problem...it says my database is read-only
there are two functions on my page, both of which will update the database, but one works all right, the other does not...
|||Hi,
Could you give us a further explaination on your issue. Do you mean that you remove the 'User Instance=True' clause and connect to your SQLServer succesfully, then fail to use one of your function to update your database while another update function works well? If so ,I think the problem should not caused by the database. Could you give us your code?
Thanks.
|||hi,
the code is a little bit long, and i really don't know what caused this problem, so i do not know which part got wrong. and i don't think you want to read all my code.
but i can do some further explain, when i remove the 'User Instance=True', and use the 'AttachDB' clause, the database connected dynamically, but in SQL Management Studio, i see a 'Read-Only' label after my database, and my database is displayed in gray.
so would you tell me why my database is connected as read-only? and how can i solve this problem?
Hi,
You need Read/Write permission on both MDF and LDF in order to editing data. If you're using IIS 6.0, you need to add Network Process account and give Read/Write permission to these two files. You also need to detach the database before changing the permissions on the file.
You can do this using SSEUtil.exe tool:http://www.microsoft.com/downloads/details.aspx?FamilyID=FA87E828-173F-472E-A85C-27ED01CF6B02&displaylang=en
Thanks.
|||hi,
all solved, thanks man!