Showing posts with label size. Show all posts
Showing posts with label size. Show all posts

Thursday, March 22, 2012

][SQL Server]Cannot sort a row of size

Cannot sort a row of size 8155, which is greater than the
allowable maximum of 8094.][SQL Server 7.0]
Does anybody known how to fix this'"Jorge Balzo" <jbalzo@.eclac.cl> wrote:
> Cannot sort a row of size 8155, which is greater than the
> allowable maximum of 8094.][SQL Server 7.0]
> Does anybody known how to fix this'
--
Hi Jorge,
You have reached the maximum row size allowed in a select statement. You
need to either modify your view or table to include varchar() columns or
remove some of the columns so that the total datalength of the data row
doesn't exceed 8094 bytes that requires sorting.
Hope this helps,
--
Eric Cárdenas
SQL Server support|||You could try the ROBUST PLAN optimizer hint. I'm not sure whether it will help in your particular
situation, though.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Jorge Balzo" <jbalzo@.eclac.cl> wrote in message news:022601c3b9e1$ed8c7050$a501280a@.phx.gbl...
> Cannot sort a row of size 8155, which is greater than the
> allowable maximum of 8094.][SQL Server 7.0]
> Does anybody known how to fix this'
>

Monday, March 19, 2012

[Sql2000] how to limit table size

hi all,
I checked out in google groups but was not able to find
the answer...
is it possible to limit size table in sql server?
how can I do it?

TIAilkaos wrote:

Quote:

Originally Posted by

hi all,
I checked out in google groups but was not able to find
the answer...
is it possible to limit size table in sql server?
how can I do it?
>
TIA


Add the table to some filegroup and then fix the total size of files in
that filegroup:

CREATE TABLE tbl
(... ) ON filegroup_xyz;

Take a look at ALTER DATABASE ... ADD FILEGROUP / FILE for more
details.

Alternatively, you could use constraints to limit the maximum number of
*rows* in a table (not necessarily comparable with the size of the
table in storage). The details of how to do this would depend on the
nature of the table and keys. For example:

/* Maximum 10,000 rows */
ALTER TABLE tbl ADD foo INT NOT NULL
CONSTRAINT ak_tbl_foo UNIQUE,
CONSTRAINT ck_tbl_foo CHECK (foo BETWEEN 1 AND 10000);

--
David Portas, SQL Server MVP

Whenever possible please post enough code to reproduce your problem.
Including CREATE TABLE and INSERT statements usually helps.
State what version of SQL Server you are using and specify the content
of any error messages.

SQL Server Books Online:
http://msdn2.microsoft.com/library/...US,SQL.90).aspx
--|||

Quote:

Originally Posted by

>"David Portas" <REMOVE_BEFORE_REPLYING_dportas@.acm.org>


thanks a lot for you (very quick!) answer.