Re: Convert block dump data (data type number)

  • From: "Stefan Knecht" <knecht.stefan@xxxxxxxxx>
  • To: ax.mount@xxxxxxxxx
  • Date: Wed, 19 Mar 2008 14:10:08 +0100

Hi Alex

Check this post by Jonathan:
http://www.jlcomp.demon.co.uk/number_format.html

Cheers

Stefan


On Wed, Mar 19, 2008 at 1:36 PM, amonte <ax.mount@xxxxxxxxx> wrote:

> Hi
>
> I have dumped a block and trying to see the data it contains, for the
> varchar2 it's quite simple we simply convert hex to ascii but for number I
> cant find a suitable way, does anyone know how to convert this data?
>
> select
>    dbms_rowid.rowid_to_absolute_fno(rowid, 'SCOTT', 'EMP') ABS_FNO,
>    dbms_rowid.rowid_relative_fno(rowid) REL_FNO,
>    dbms_rowid.rowid_block_number(rowid) BLOCKNO,
>    dbms_rowid.rowid_row_number(rowid) ROWNO,
>    empno, ename
> from emp
> where empno = 7369
>
>
>    ABS_FNO    REL_FNO    BLOCKNO      ROWNO      EMPNO ENAME
> ---------- ---------- ---------- ---------- ---------- ----------
>          8          8         10          0       7369 SMITH
>
> so I dump block 10 and check for row 0 and got this:
>
> tab 0, row 0, @0xb94
> tl: 38 fb: --H-FL-- lb: 0x0  cc: 8
> col  0: [ 3]  c2 4a 46 --> EMPNO
> col  1: [ 5]  53 4d 49 54 48 --> ENAME
> col  2: [ 5]  43 4c 45 52 4b
> col  3: [ 3]  c2 50 03
> col  4: [ 7]  77 b4 0c 11 01 01 01
> col  5: [ 2]  c2 09
> col  6: *NULL*
> col  7: [ 2]  c1 15
>
> so converting 53 4d 49 54 48 to ascii we got SMITH but to get the EMPNO
> (7369) using c2 4a 46 ?
>
> TIA
>
> Alex
>
>


-- 
=========================

Stefan P Knecht
Senior Consultant
Infrastructure Managed Services

Trivadis AG
Europa-Strasse 5
CH-8152 Glattbrugg

Phone +41-44-808 70 20
Fax +41-808 70 12
Mobile +41-79-571 36 27
stefan.knecht@xxxxxxxxxxxx
http://www.trivadis.com

OCP 9i/10g SCSA SCNA
=========================

Other related posts: