Solved

Negative Number ??

Posted on 2004-04-27
3
657 Views
Last Modified: 2013-12-11
Hello, I do a query about bytes send/received via SQL*NET by an user, and the result is like this:

NAME                                                             VALUE    
------------------------------------------------------ ----------
bytes sent via SQL*Net to client                        -1,357E09

VAULE is NUMBER in the view V$SESSTAT,

I do not understand why VALUE is negative, is a format question ?? I don´t know.

Thanks in advance.
0
Comment
Question by:core007
  • 2
3 Comments
 
LVL 10

Expert Comment

by:SDutta
ID: 10930685
This was identified as a bug and fixed in 8.1.7, what version are you on ?

Basically the reason given was if the database stays up for too long this number becomes large enough to wrap around and show up as a negative number. This was also related to using parallel query if parallel_max_servers was set > 0.
0
 

Author Comment

by:core007
ID: 10937159
My version is 8.1.6.

Another question about this is if this negative number is a real value. That is, if the real value is the shown number, but positive, not negative. Or the shown value is a wrong value?
I don´t know.

Thanks in advance, again.
0
 
LVL 10

Accepted Solution

by:
SDutta earned 125 total points
ID: 10939362
There are a couple of open bugs on wrong values, including negative, in v$sesstat (Bugs 1936101 and 1713403). All these values get reset when you shutdown the database and bring it up again.

The negative number is generally real value that has cycled over. When Oracle uses a 32bit integer to hold the value, once you exceed 2^32 or about 2.1 billion the number becomes -1 and increments again. To get the real value, you could take the absolute value of the number and add it to the maximum positive value that the statistic can hold if the count has not cycled more than once. The problem is knowing how many times it has cycled.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Oracle Subquery bad Join 11 60
Clone Oracle 12c Database 5 43
grouping on time windows 6 43
Oracle SQL Select unique values from two columns 4 35
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now