Microsoft Knowledge Base Email Alertz

You receive a Database Results Wizard Error error message when you browse an ASP page after you upgrade to FrontPage 2003 or to FrontPage 2002 SP3

Search KbAlertz

Advanced Search

Receive Microsoft Knowledge Base articles by E-Mail?

Every night we scan the Microsoft Knowledge Base. If technologies you're interested in are updated, we'll send you an e-mail. You only get one e-mail a day, and only when new articles are added.

Click here to create a
FREE account
Already have an account?
[Click here to Login]











Microsoft Knowledge Base Article

This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks

Article ID: 907307 - Last Review: May 2, 2006 - Revision: 2.1

You receive a "Database Results Wizard Error" error message when you browse an ASP page after you upgrade to FrontPage 2003 or to FrontPage 2002 SP3

SYMPTOMS

Consider the following scenario. You upgrade Microsoft FrontPage 2002 to Microsoft Front Page 2002 Service Pack 3 (SP3) or to Microsoft Office FrontPage 2003. You open an active server page (ASP) page that was created by using the Database Results Wizard. You save the ASP page. In this scenario, you may receive the following error message when you browse the ASP page:
Database Results Wizard Error The operation failed. If this continues, please contact your server administrator.
Additionally, if you set the fp_DEBUG value to True in the Fpdbrgn1.inc file in the _fpclass folder, you receive the following error message when you browse the ASP page:
Database Results Wizard Error Your page contains a query with user input parameters that could not be resolved. This could happen if your DatabaseRegionStart webbot has an empty or missing s-columnnames or s-columntypes attributes. You may need to read Microsoft Knowledge Base Article 817029. One or more form fields were empty. You should provide default values for all form fields that are used in the query.
Note This behavior also occurs if you browse an ASP page that was created by using the Database Results Wizard in FrontPage 2003.

This behavior occurs when you use a custom SQL query that has parameters in the Database Results Wizard.

CAUSE

This problem occurs because the .inc files are updated when you upgrade to FrontPage 2002 SP3 or to FrontPage 2003. After the .inc files are updated, the custom SQL queries that have parameters are no longer processed by these .inc files.

Note This problem occurs only if the parameter in the custom SQL query is outside the WHERE clause.

RESOLUTION

To resolve this problem, obtain the latest service pack for Microsoft Office 2003. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
887616  (http://kbalertz.com/Feedback.aspx?kbNumber=887616/ ) Description of Office 2003 Service Pack 2
After you install Microsoft Office 2003 SP2, you have to reopen and save each ASP page that was created by using the Database Results Wizard. When you save the ASP page, the .inc files will be rewritten.

MORE INFORMATION

The .inc files are include files that are generated by the FrontPage Database Results Wizard. The .inc files are saved in the _fpclass folder of a Web site. The .inc files contain all the database functionality. Editing the .inc files is not supported in FrontPage.

The following list describes three common .inc files:
  • The Fpdblib.inc file

    This .inc file is the database library file. The Fpdblib.inc file contains functions and subroutines that perform a variety of tasks.
  • The Fpdbrgn1.inc file

    This .inc file is the first part of a database results region. The Fpdbrgn1.inc file opens the database connection and starts the loop through the data.
  • The Fpdbrgn2.inc file

    This .inc file is the second part of a database results region. The Fpdbrgn2.inc file closes the database connection and ends the loop through the data.
The following text shows examples of invalid queries against a database:
Insert Into Categories (CategoryID, CategoryName, Description) Values (::UniqID::, '::CategName::', '::CategDesc::') 

SELECT * FROM products WHERE ::param:: = 1

SELECT * FROM products WHERE CategoryID ::foo:: 2

SELECT Count(*) AS ::name:: FROM products

SELECT * FROM products WHERE upper(ProductName) = upper('::param::')

SELECT * FROM Employees WHERE InvalidColumName=::foo::

The following text shows examples of valid queries against a database.

Note All FrontPage parameterized custom queries should follow the CLAUSE + (Column name + Operator + ::parameter::) format. All existing queries that do not follow this format cannot be authored by using the FrontPage Database Results Wizard. If you use the correct syntax and still receive the "The custom query contains errors" error, make sure that the case of the field names in the query matches the case of the field names in the tables.
Update Categories Set Description = '::CategDesc::' Where CategoryID = '::CategID::'

SELECT * FROM products WHERE (ProductName LIKE '%::searchtext::%')

SELECT Products.ProductID, Products.ProductName, Categories.CategoryName FROM Categories INNER JOIN Products ON Categories.CategoryID = Products.CategoryID WHERE Categories.CategoryName LIKE '%::CatName::%'

SELECT FirstName, LastName, HireDate FROM Employees WHERE HireDate > '::HireDate::'

SELECT * FROM Categories,Products WHERE Categories.CategoryID=::ID:: and Categories.CategoryID=Products.CategoryID

SELECT ProductID, ProductName FROM products WHERE ( (CategoryID=::catid::) AND (ProductName LIKE '%::searchtext::%') )
 
SELECT Count(*) AS NumberOfProducts FROM products  WHERE (ProductName LIKE '%::searchtext::%')

SELECT Count(*) AS ProductCount FROM products HAVING (ProductName LIKE '%::SEARCHTEXT::%')

SELECT * FROM products ORDER BY ::SortFld:: ASC

REFERENCES

For more information, click the following article number to view the article in the Microsoft Knowledge Base:
871267  (http://kbalertz.com/Feedback.aspx?kbNumber=871267/ ) You receive an "Unable to find operator in query string" error message when you use the ORDER BY parameter in a custom SQL query in FrontPage 2003

APPLIES TO
  • Microsoft Office FrontPage 2003
Keywords: 
kberrmsg kbtshoot kbprb KB907307
       

Community Feedback System

Very often, it takes hours to solve a problem. Very often, you've looked high and low, and have tried a lot of solutions. When you finally found it, chances are, it was because someone else helped you. Here's your chance to give back. Use our community feedback tool to let others know what worked for you and what didn't.

Please also understand that the community feedback system is not warranted to be correct, it's simply a system that we've built to let people try and help each other. If something in a feedback response doesn't make sense to you, or you're not comfortable making changes that the feedback talks about (like registry edits), please consult a professional.

Thank you for using kbAlertz.com Feedback System.

-- Scott Cate