Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

error 2778 not true

4 posts in General Discussion Last posting was on 2011-03-09 15:34:12.0Z
djmodica Posted on 2011-03-03 15:02:57.0Z
Sender: 1f7d.4d6bedbe.1804289383@sybase.com
From: djmodica
Newsgroups: sybase.public.ase.general
Subject: error 2778 not true
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4d6fada1.2f1d.1681692777@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 3 Mar 2011 07:02:57 -0800
X-Trace: forums-1-dub 1299164577 10.22.241.41 (3 Mar 2011 07:02:57 -0800)
X-Original-Trace: 3 Mar 2011 07:02:57 -0800, 10.22.241.41
Lines: 8
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30017
Article PK: 79246

i am getting an error 2778 from update index statistics.
problem is, the table exists. its in sysobjects with type
"U", its in systabstats. for all intents an purposes it
looks like any other table. zero rows. why is update index
statistics throwing an error ?
anyone seen this ?

thanks


Sherlock, Kevin [TeamSybase] Posted on 2011-03-03 15:43:53.0Z
From: "Sherlock, Kevin [TeamSybase]" <kevin.sherlock@teamsybase.com>
Newsgroups: sybase.public.ase.general
References: <4d6fada1.2f1d.1681692777@sybase.com>
Subject: Re: error 2778 not true
Lines: 15
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5512
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5512
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4d6fb739@forums-1-dub>
Date: 3 Mar 2011 07:43:53 -0800
X-Trace: forums-1-dub 1299167033 10.22.241.152 (3 Mar 2011 07:43:53 -0800)
X-Original-Trace: 3 Mar 2011 07:43:53 -0800, vip152.sybase.com
X-Authenticated-User: teamsybase
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30018
Article PK: 79247

what is the output of

select name,type,user_name(uid) from sysobjects where name = 'yourtablename'

<djmodica> wrote in message news:4d6fada1.2f1d.1681692777@sybase.com...
>i am getting an error 2778 from update index statistics.
> problem is, the table exists. its in sysobjects with type
> "U", its in systabstats. for all intents an purposes it
> looks like any other table. zero rows. why is update index
> statistics throwing an error ?
> anyone seen this ?
>
> thanks


Bret Halford Posted on 2011-03-03 18:48:03.0Z
From: Bret Halford <bret@sybase.com>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.14) Gecko/20110221 Thunderbird/3.1.8
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: error 2778 not true
References: <4d6fada1.2f1d.1681692777@sybase.com> <4d6fb739@forums-1-dub>
In-Reply-To: <4d6fb739@forums-1-dub>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4d6fe263$1@forums-1-dub>
Date: 3 Mar 2011 10:48:03 -0800
X-Trace: forums-1-dub 1299178083 10.22.241.152 (3 Mar 2011 10:48:03 -0800)
X-Original-Trace: 3 Mar 2011 10:48:03 -0800, vip152.sybase.com
Lines: 59
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30019
Article PK: 79248


On 3/3/2011 8:43 AM, Sherlock, Kevin [TeamSybase] wrote:
> what is the output of
>
> select name,type,user_name(uid) from sysobjects where name = 'yourtablename'
>
> <djmodica> wrote in message news:4d6fada1.2f1d.1681692777@sybase.com...
>> i am getting an error 2778 from update index statistics.
>> problem is, the table exists. its in sysobjects with type
>> "U", its in systabstats. for all intents an purposes it
>> looks like any other table. zero rows. why is update index
>> statistics throwing an error ?
>> anyone seen this ?
>>
>> thanks

Note: It is generally helpful to include your server version
(select @@version) and the exact text of any messages you
are asking about.

The ASE code raises the error if it determines
that the object is not a user table or system table,
or if it is a "fake" table (sysprocesses, syslocks,
etc. are examples, their contents are created on the fly
from memory structures) or a system table that does
not have an OAM page (sysgams, syslogs), or if the
table is a "definition time table" (system created
while processing procedures).

The wording of the error isn't very good - i.e. if you
run update stats on syslogs, which is a very real table,
the wording is obviously wrong:

1> update index statistics syslogs
2> go
Msg 2778, Level 12, State 5:
Server 'rel155_bret_sun2', Line 1:
The object 'syslogs' is not a table. Update statistics can be used only
on user tables or system tables

CR 634807 is open to improve the message.

My guess here for your case is that ASE isn't recognizing
the table as a user table. There are bits in the sysdatabases.sysstat
field that identify system or user tables, I believe ASE looks
at this bitmap rather than the "type" field.

So in addition to what Kevin is asking for, what is the value for
the status field?

select
name,
sysstat & 1 as "is_system",
sysstat & 4 as "is_user"
from
sysobjects
where
id = object_id("<tablename>")

Do dbcc checkalloc and dbcc checktable run clean on this table?


djmodica Posted on 2011-03-09 15:34:12.0Z
Sender: 56c8.4d779c25.1804289383@sybase.com
From: djmodica
Newsgroups: sybase.public.ase.general
Subject: Re: error 2778 not true
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4d779df4.5715.1681692777@sybase.com>
References: <4d6fe263$1@forums-1-dub>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 9 Mar 2011 07:34:12 -0800
X-Trace: forums-1-dub 1299684852 10.22.241.41 (9 Mar 2011 07:34:12 -0800)
X-Original-Trace: 9 Mar 2011 07:34:12 -0800, 10.22.241.41
Lines: 72
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:30034
Article PK: 79262


> On 3/3/2011 8:43 AM, Sherlock, Kevin [TeamSybase] wrote:
> > what is the output of
> >
> > select name,type,user_name(uid) from sysobjects where
> name = 'yourtablename' >
> > <djmodica> wrote in message
> news:4d6fada1.2f1d.1681692777@sybase.com... >> i am
> getting an error 2778 from update index statistics. >>
> problem is, the table exists. its in sysobjects with type
> >> "U", its in systabstats. for all intents an purposes it
> >> looks like any other table. zero rows. why is update
> index >> statistics throwing an error ?
> >> anyone seen this ?
> >>
> >> thanks
>
> Note: It is generally helpful to include your server
> version (select @@version) and the exact text of any
> messages you are asking about.
>
> The ASE code raises the error if it determines
> that the object is not a user table or system table,
> or if it is a "fake" table (sysprocesses, syslocks,
> etc. are examples, their contents are created on the fly
> from memory structures) or a system table that does
> not have an OAM page (sysgams, syslogs), or if the
> table is a "definition time table" (system created
> while processing procedures).
>
> The wording of the error isn't very good - i.e. if you
> run update stats on syslogs, which is a very real table,
> the wording is obviously wrong:
>
> 1> update index statistics syslogs
> 2> go
> Msg 2778, Level 12, State 5:
> Server 'rel155_bret_sun2', Line 1:
> The object 'syslogs' is not a table. Update statistics can
> be used only on user tables or system tables
>
> CR 634807 is open to improve the message.
>
> My guess here for your case is that ASE isn't recognizing
> the table as a user table. There are bits in the
> sysdatabases.sysstat field that identify system or user
> tables, I believe ASE looks at this bitmap rather than the
> "type" field.
>
> So in addition to what Kevin is asking for, what is the
> value for the status field?
>
> select
> name,
> sysstat & 1 as "is_system",
> sysstat & 4 as "is_user"
> from
> sysobjects
> where
> id = object_id("<tablename>")
>
> Do dbcc checkalloc and dbcc checktable run clean on this
> table?

well, after doing many of the things pointed out in the 2
responses - thanks guys - i finally got a message saying
that the table was in the process of being dropped and i
couldnt perform any actions against it other than dropping
it. how it wound up in this state i can only guess(before my
time). but i dropped the table and this database is clean
again.

thanks for all the suggestions and help !