• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Server: Msg 511

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i get this error when i run my query...

Server: Msg 511, Level 16, State 1, Line 5
Cannot create a row of size <rowlength> which is greater than the allowable maximum of 8060.
The statement has been terminated.


how can i resolve it ???

Regards
Saumya
 
author & internet detective
Posts: 42152
937
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First, can you provide some more information? Like what database you are using?
 
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This looks like a MS SQL Server error. Correct?

I suspect you are trying to update or insert a row that is larger than 8060 bytes.

You have a few options:

1. Shorten the data (i.e., is there a string that can be truncated?)
2. Convert any large char or varchar fields to text datatype
2. Move one or more columns to different tables.
 
Saumya Nair
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, i m using SQL server.

Our project is a maintenance project so can't make those major changes like shifting the columns to other table.We are trying by reducing the length of the fields. Is any other solution possible ??? As it there can be a data which exceeds 8060 bytes..

Regards,
Saumya
 
Scott Johnson
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

As it there can be a data which exceeds 8060 bytes..



Yes, you can switch the datatype from char/varchar to text. In SQL Server 2000 (not sure about 2005), it can hold 2^31 -1 bytes per row.
 
Saumya Nair
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The data in each field is within the defiend range.This error occurs when the total data in the table exceeds 8060 bytes. I tried changing the length of different columns but in no way can i reduce it such a value,such that it is less than 8060 bytes. The existing data might get lost in that case. Tried reducing the length of the columns which need not be that large but still the error occurs


Regards,
Saumya
 
reply
    Bookmark Topic Watch Topic
  • New Topic