Troubleshoot permissions problems, Microsoft error messages, and MySQL error messages in Dreamweaver.

Märkus.

The user interface has been simplified in Dreamweaver CC and later. As a result, you may not find some of the options described in this article in Dreamweaver CC and later. For more information, see this article.

Troubleshoot permissions problems

One of the most common problems is insufficient folder or file permissions. If your database is located on a Windows 2000 or Windows XP computer and you receive an error message when you try to view a dynamic page in a web browser or in Live view, the error might be due to a permissions problem.

The Windows account attempting to access the database doesn’t have sufficient permissions. The account might be either the anonymous Windows account (by default, IUSR_computername) or a specific user account, if the page has been secured for authenticated access.

You must change the permissions to give the IUSR_computername account the correct permissions so the web server can access the database file. In addition, the folder containing the database file must also have certain permissions set to write to that database.

If the page is meant to be accessed anonymously, give the IUSR_computername account full control to the folder and database file, as described in the procedure below.

Additionally, if the path to the database is being referenced using UNC (\\Server\Share), make sure the Share Permissions give the IUSR_computername account full access. This step applies even if the share is on the local web server.

If you copy the database from another location, it may not inherit the permissions from its destination folder and you may have to change the permissions for the database.

Check or change the database file permissions (Windows XP)

  1. Make sure that you have administrator privileges on the computer.
  2. In Windows Explorer, locate the database file or the folder containing the database, right-click the file or folder, and select Properties.
  3. Select the Security tab.

    Märkus.

    This step applies only if you have an NTFS file system. If you have an FAT file system, the dialog box won't have a Security tab.

  4. If the IUSR_computername account is not listed in the Group or User Names list, click the Add button to add it.
  5. In the Select Users or Groups dialog box, click Advanced.

    The dialog box changes to show more options.

  6. Click Locations and select the computer’s name.
  7. Click Find Now to display a list of account names associated with the computer.
  8. Select the IUSR_computername account and click OK; then click OK again to clear the dialog box.
  9. To assign the IUSR account full permissions, select Full Control and click OK.

Check or change the database file permissions (Windows 2000)

  1. Make sure that you have administrator privileges on the computer.
  2. In Windows Explorer, locate the database file or the folder containing the database, right-click the file or folder, and select Properties.
  3. Select the Security tab.

    Märkus.

    This step applies only if you have an NTFS file system. If you have an FAT file system, the dialog box won't have a Security tab.

  4. If the IUSR_computername account is not listed among the Windows accounts in the File Permissions dialog box, click the Add button to add it.
  5. In the Select Users, Computers, or Groups dialog box, select the computer name from the Look In menu to display a list of account names associated with the computer.
  6. Select the IUSR_computername account and click Add.
  7. To assign the IUSR account full permissions, select Full Control from the Type Of Access menu and click OK.

    For added security, permissions can be set so that Read permission is disabled for the web folder containing the database. Browsing the folder won’t be permitted, but web pages will still be able to access the database.

    For more information about the IUSR account and web server permissions, see the following TechNotes on the Adobe Support Center:

Troubleshoot Microsoft error messages

These Microsoft error messages can occur when you request a dynamic page from the server if you use Internet Information Server (IIS) with a Microsoft database system such as Access or SQL Server.

Märkus.

Adobe does not provide technical support for third-party software such as Microsoft Windows, and IIS. If this information does not fix your problem, please contact Microsoft technical support or visit the Microsoft support website at http://support.microsoft.com/.

For more information on 80004005 errors, see “INFO: Troubleshooting Guide for 80004005 Errors in Active Server Pages and Microsoft Data Access Components (Q306518),” on the Microsoft website at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q306518.

[Reference]80004005—Data sourcename not found and no default driver specified

This error occurs when you attempt to view a dynamic page in a web browser or in Live view. The error message may vary depending on your database and web server. Other variations of the error message include:

  • 80004005—Driver's SQLSetConnectAttr failed

  • 80004005—General error unable to open registry key 'DriverId'

    Here are possible causes and solutions:

  • The page can’t find the DSN. Make sure a DSN has been created on both the web server and on the local machine.

  • The DSN might have been set up as a user DSN, not as a system DSN. Delete the user DSN and create a system DSN to replace it.

Märkus.

If you don’t delete the user DSN, the duplicate DSN names produce a new ODBC error.

If you use Microsoft Access, the database file (.mdb) might be locked. The lock might be due to a DSN with a different name accessing the database. In Windows Explorer, search for the lock file (.ldb) in the folder containing the database file (.mdb) and delete the .ldb file. If another DSN is pointing to the same database file, delete the DSN to prevent the error in the future. Reboot the computer after making any changes.

[Reference]80004005—Couldn’t use‘(unknown)’; file already in use

This error occurs when you use a Microsoft Access database and attempt to view a dynamic page in a web browser or in Live view. Another variation of this error message is “80004005—Microsoft Jet database engine cannot open the file (unknown).”

The probable cause is a permissions problem. Here are some specific causes and solutions:

  • The account being used by Internet Information Server (usually IUSR) might not have the correct Windows permissions for a file-based database or for the folder containing the file. Check the permissions on the IIS account (IUSR) in the user manager.

  • You might not have permission to create or destroy temporary files. Check the permissions on the file and the folder. Make sure that you have permission to create or destroy any temporary files. Temporary files are usually created in the same folder as the database, but the file may also be created in other folders such as /Winnt.

  • In Windows 2000, the time-out value may need to be changed for the Access database DSN. To change the time-out value, select Start > Settings > Control Panel > Administrative Tools > Data Sources (ODBC). Click the System tab, highlight the correct DSN, and click the Configure button. Click the Options button and change the Page Timeout value to 5000.

    If you still have problems, see the following Microsoft Knowledge Base articles:

  • PRB: 80004005 “Couldn't Use ‘(unknown)’; File Already in Use” at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q174943.

  • PRB: Microsoft Access Database Connectivity Fails in Active Server Pages at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q253604.

  • PRB: Error “Cannot Open File Unknown” Using Access at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q166029.

[Reference]80004005—Logon Failed()

This error occurs when you use Microsoft SQL Server and attempt to view a dynamic page in a web browser or in Live view.

This error is generated by SQL Server if it doesn’t accept or recognize the logon account or password being submitted (if you’re using standard security), or if a Windows account does not map to a SQL account (if you’re using integrated security).

Here are possible solutions:

  • If you use standard security, the account name and password might be incorrect. Try the system Admin account and password (UID= “sa” and no password), which must be defined in the connection string line. (DSNs do not store user names and passwords.)

  • If you use integrated security, check the Windows account calling the page and find its mapped SQL account (if any).

  • SQL Server does not allow an underscore in SQL account names. If someone manually maps the Windows IUSR_machinename account to a SQL account of the same name, it will fail. Map any account that uses an underscore to an account name on SQL that does not use an underscore.

[Reference]80004005—Operation mustuse an updateable query

This error occurs when an event is updating a recordset or inserting data in a recordset.

Here are possible causes and solutions:

  • The permissions set on the folder containing the database are too restrictive. IUSR privileges must be set to read/write.

  • The permissions on the database file itself does not have full read/write privileges in effect.

  • The database might be located outside the Inetpub/wwwroot directory. Though you can view and search the data, you might not be able to update it unless the database is located in the wwwroot directory.

  • The recordset is based on a non-updateable query. Joins are good examples of non-updateable queries within a database. Restructure your queries so they are updateable.

    For more information on this error, see “PRB: ASP ‘Error The Query Is Not Updateable’ When You Update Table Record,” in the Microsoft Knowledge Base at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q174640.

[Reference]80040e07—Data type mismatchin criteria expression

This error occurs when the server tries to process a page containing an Insert Record or Update Record server behavior, and the server behavior attempts to set the value of a Date/Time column in a Microsoft Access database to an empty string ("").

Microsoft Access has strong data typing; it imposes a rigorous set of rules on given column values. The empty string value in the SQL query cannot be stored in an Access Date/Time column. Currently, the only known workaround is to avoid inserting or updating Date/Time columns in Access with empty strings ("") or with any other value that does not correspond to the range of values specified for the data type.

[Reference]80040e10—Too few parameters

This error occurs when a column specified in your SQL query does not exist in the database table. Check the column names in your database table against the SQL query. The cause of this error is often a typographical error.

[Reference]80040e10—COUNT fieldincorrect

This error occurs when you preview a page containing an Insert Record server behavior in a web browser and try to use it to insert a record in a Microsoft Access database.

You might be trying to insert a record into a database field that has a question mark (?) in its field name. The question mark is a special character for some database engines, including Microsoft Access, and should not be used for database table names or field names.

Open your database system and delete the question mark (?) from the field names, and update the server behaviors on your page that refer to this field.

[Reference]80040e14—Syntax errorin INSERT INTO statement

This error occurs when the server tries to process a page containing an Insert Record server behavior.

This error typically results from one or more of the following problems with the name of a field, object, or variable in the database:

  • Using a reserved word as a name. Most databases have a set of reserved words. For example, “date” is a reserved word and cannot be used for column names in a database.

  • Using special characters in the name. Examples of special characters include:

    . / * : ! # & - ?

  • Using a space in the name.

    The error can also occur when an input mask is defined for an object in the database, and the inserted data does not conform to the mask.

    To fix the problem, avoid using reserved words such as “date”, “name”, “select”, “where,” and “level” when specifying column names in your database. Also, eliminate spaces and special characters.

    See the following web pages for lists of reserved words for common database systems:

  • Microsoft Access at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q209187

  • MySQL at http://dev.mysql.com/doc/mysql/en/reserved-words.html

[Reference]80040e21—ODBC erroron Insert or Update

This error occurs when the server tries to process a page containing an Update Record or Insert Record server behavior. The database cannot handle the update or insert operation the server behavior is trying to perform.

Here are possible causes and solutions:

  • The server behavior is trying to update a database table’s auto-number field or to insert a record into an auto-number field. Because auto-number fields are populated automatically by the database system, any attempt to externally populate them with a value fails.

  • The data the server behavior is updating or inserting is the wrong type for the database field, such as inserting a date into a Boolean (yes/no) field, inserting a string into a numeric field, or inserting an improperly formatted string into Date/Time field.

[Reference]800a0bcd—Either BOFor EOF is true

This error occurs when you attempt to view a dynamic page in a web browser or in Live view.

The problem occurs when the page tries to display data from an empty recordset. To solve the problem, apply the Show Region server behavior to the dynamic content to be displayed on the page, as follows:

  1. Highlight the dynamic content on the page.

  2. In the Server Behaviors panel, click the Plus (+) button and select Show Region > Show Region If Recordset Is Not Empty.

  3. Select the recordset supplying the dynamic content and click OK.

  4. Repeat steps 1 to 3 for each element of dynamic content on the page.

Troubleshoot MySQL error messages

One common error message that you might encounter when testing a PHP database connection to MySQL 4.1 is “Client does not support authentication protocol requested. Consider upgrading MySQL client.”

You may have to revert to an earlier version of MySQL, or install PHP 5 and copy some dynamic link libraries (DLLs). For detailed instructions, see Setting up a PHP development environment.

See töö on litsentseeritud Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported litsentsiga  Süsteemi Creative Commons tingimused ei kehti Twitter™-i ja Facebooki postitustele.

Juriidilised märkused   |   Privaatsuspõhimõtted veebis