The error: "An error occurred on a query to database [databasename]. Server user [domain/login]; is not a valid user in database [databasename]. The item [databasename] in use - skipped" is displayed when trying to connect to an SQL database.

Article:TECH28835  |  Created: 2006-01-18  |  Updated: 2012-03-21  |  Article URL http://www.symantec.com/docs/TECH28835
Article Type
Technical Solution

Product(s)


Issue



The error: "An error occurred on a query to database [databasename]. Server user [domain/login]; is not a valid user in database [databasename]. The item [databasename] in use - skipped" is displayed when trying to connect to an SQL database.


Error



An error occurred on a query to database [databasename]. Server user [domain/login]; is not a valid user in database [databasename]. The item [databasename] in use - skipped


Solution



The logon account tied to the resource in the job does not have the correct permissions within SQL.

1. Open SQL EXpress
2. Expand the Security tab
3. Right-click Logins, and click New Login... (Figure 1)

Figure 1
 

4. Type the logon account specified in the job in the Name box (Figure 2)

Figure 2
 

5. Select the Server Roles tab
6. Select the checkbox beside System Administrators (Figure 3)

Figure 3
 

7. Click the Database Access tab
8. Below the Permit column, select the checkbox beside the database that needs to backed up
9. Below the Permit in Database Role column, select the checkbox beside db_datareader and db_datawriter (Figure 4)

Figure 4
 

10. Repeat steps 8 and 9 for each database that needs to be backed up
11. Click OK

If the account already has permissions, change the SQL resource logon account for the job.

To change the logon account, do the following:

1. Select the data for backup (Figure 5)

Figure 5
 

3. In the Properties pane, click Resource Credentials under Source
4. Select the resource for which the logon account has to be changed
5. Click Change from the right pane (Figure 7)

Figure 6
 

6. Select the logon account to use for the backup selection, or click New and create a new logon account
7. Click OK (Figure 8)

Figure 7
 

After an appropriate logon account is selected, the job is executed using that account.



Legacy ID



263647


Article URL http://www.symantec.com/docs/TECH28835


Terms of use for this information are found in Legal Notices