Home » SQL & PL/SQL » SQL & PL/SQL » VSIZE()
VSIZE() [message #253277] Mon, 23 July 2007 06:42 Go to next message
MEEENAR
Messages: 72
Registered: May 2005
Location: CHENNAI
Member
vsize(3.141) answer is 4
& FOR
vsize(384838) answer is 4. Plase explain.
Re: VSIZE() [message #253279 is a reply to message #253277] Mon, 23 July 2007 06:52 Go to previous messageGo to next message
ammishra
Messages: 179
Registered: January 2007
Location: india
Senior Member
In Oracle/PLSQL, the vsize function returns the number of bytes in the internal representation of an expression.might be both case oracl having same number of byte..
Re: VSIZE() [message #253281 is a reply to message #253277] Mon, 23 July 2007 06:58 Go to previous messageGo to next message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
SQL> select dump(3.141) from dual;
DUMP(3.141)
------------------------
Typ=2 Len=4: 193,4,15,11

1 row selected.

SQL> select dump(384838) from dual;
DUMP(384838)
-------------------------
Typ=2 Len=4: 195,39,49,39

1 row selected.

Each one uses 4 bytes to be stored.

Regards
Michel
Re: VSIZE() [message #253286 is a reply to message #253281] Mon, 23 July 2007 07:03 Go to previous messageGo to next message
MEEENAR
Messages: 72
Registered: May 2005
Location: CHENNAI
Member
Thanks a lot
what is the vsize(1.453) , vsize(9.7586321)
Re: VSIZE() [message #253294 is a reply to message #253286] Mon, 23 July 2007 07:24 Go to previous messageGo to next message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
SQL> select vsize(1.453) , vsize(9.7586321) from dual;
VSIZE(1.453) VSIZE(9.7586321)
------------ ----------------
           4                6

1 row selected.

Why don't you try?

Regards
Michel
Re: VSIZE() [message #253618 is a reply to message #253277] Tue, 24 July 2007 07:27 Go to previous message
gintsp
Messages: 118
Registered: February 2007
Senior Member
Following for example is even more impressive Smile
SQL> select vsize(999), vsize(100000000000000000) from dual;

VSIZE(999) VSIZE(100000000000000000)
---------- -------------------------
         3                         2

Gints Plivna
http://www.gplivna.eu
Previous Topic: How to delete records based on two tables using join without sub query?
Next Topic: get first n last day
Goto Forum:
  


Current Time: Thu Dec 05 15:58:23 CST 2024