Thursday, April 23, 2009

Error when click on EditForm.aspx in SharePoint custom list


Issue: When clicking on EditForm.aspx of a SharePoint list it redirects to below page with error message "Some part of your SQL statement is nested too deeply. Rewrite the query or break it up into smaller queries."
Reason: The SQL query passed when opening EditForm.aspx is getting multiple values for some field/fields of the list. This may be possible if you are updating some of the columns in list through workflow. Specially when the columns are lookup column or choice column. When SQL query is run on EditForm.aspx, it will return one value updated through workflow as well as another default value of choice field. Once the list item shows this error it gets corrupted.
Solution: Include all the values updated through workflow in the choice list of the column. In this case, workflow updates the column value which will be one of the choice and hence multiple values will not be fetched through SQL query.
Hope this works for most. As it solved my issue which i was getting since many weeks.

1 comment:

  1. Can you please explain what you mean by "Include all the values updated through workflow in the choice list of the column" in the solution?

    ReplyDelete