Microsoft Knowledge Base Email Alertz

(896950) - Describes a problem in Office Access where you receive an error message when you run a query. Or, you do not receive an error message but a Memo field is truncated to 255 characters.

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: 896950 - Last Review: September 17, 2011 - Revision: 5.0

Error message when you run a query in Access: "The field is too small to accept the amount of data you attempted to add"

On This Page

SYMPTOMS

In Microsoft Office Access, you may create a query that has the UniqueValues query property set to Yes, and the query may include a Memo field. When you run the query, you may receive the following error message:
The field is too small to accept the amount of data you attempted to add. Try inserting or pasting less data.
Additionally, the query may run without an error message. However, the data that is returned in the memo field is truncated to 255 characters.

CAUSE

This problem occurs because when you set the UniqueValues query property to Yes, a DISTINCT keyword is added to the resulting SQL statement. The DISTINCT keyword directs Access to perform a comparison between records. When Access performs a comparison between two Memo fields, Access treats the fields as Text fields that have a 255-character limit. Sometimes Memo field data that is larger than 255 characters will generate the error message that is mentioned in the "Symptoms" section. Sometimes only 255 characters are returned from the Memo field.

WORKAROUND

To work around this problem, modify the original query by removing the Memo field. Then, create a second query that is based on both the table and the original query. This new query uses all the fields from the original query, and this new query uses the Memo field from the table. When you run the second query, the first query runs. Then, this data is used to run the second query. This behavior returns the Memo field data based on the returned data of the first query. To do this, follow these steps.

Access 2007

  1. Copy the original query, and then name this copy Backup Copy OriginalName.
  2. Right-click the original query, and then click Design View.
  3. Click the column that contains the Memo field, and then click Delete Columns in the Query Setup group on the Design tab.
  4. Save the query.
  5. On the Create tab, click Query Design in the Other group.
  6. Click the Both tab.
  7. Click the original query, and then click Add.
  8. Click the table on which the original query is based, and then click Add.
  9. Click Close.
  10. Add the fields from the original query, and then add the memo field from the table.
  11. Create a link between the table and the query by using the appropriate field.

    For more information about how to use joins in Microsoft Query, click the following article number to view the article in the Microsoft Knowledge Base:
    136699  (http://kbalertz.com/Feedback.aspx?kbNumber=136699/ ) Description of the usage of joins in Microsoft Query
  12. Save the query.
  13. On the Design tab, click Run in the Results group.

    The query should run as expected, and the Memo field is not truncated.

Access 2003, Access 2002, and Access 2000

  1. Copy the original query, and then name this copy Backup Copy OriginalName.
  2. Click the original query, and then click Design on the Database toolbar.
  3. Click the column that contains the Memo field, and then click Delete on the Edit menu.
  4. Save the query.
  5. Double-click Create query in design view.
  6. Click the Both tab.
  7. Click the original query, and then click Add.
  8. Click the table that the original query is based on, and then click Add.
  9. Click Close.
  10. Add the fields from the original query, and then add the memo field from the table.
  11. Create a link between the table and the query.

    For more information about how to create a link, click the following article number to view the article in the Microsoft Knowledge Base:
    136699  (http://kbalertz.com/Feedback.aspx?kbNumber=136699/ ) Description of the usage of joins in Microsoft Query
  12. Save the query.
  13. On the Query menu, click Run.

    The query should run as expected, and the Memo field is not truncated.

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

MORE INFORMATION

For more information about problems that may occur when you use the UniqueValues query property, click the following article number to view the article in the Microsoft Knowledge Base:
304431  (http://kbalertz.com/Feedback.aspx?kbNumber=304431/ ) You receive a "Cannot include Memo, OLE or Hyperlink Object when you select unique values" error message

APPLIES TO
  • Microsoft Office Access 2007
  • Microsoft Office Access 2003
  • Microsoft Access 2002 Standard Edition
  • Microsoft Access 2000 Standard Edition
Keywords: 
kbdesign kbdatabase kbquery kbtshoot kbprb KB896950
       

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