To: "Dunn, Robert" 
> Hello Ari,
> 
> I'd like to take this opportunity to thank you for providing a web page that
> is usefull as it is interesting.  Keep the information flowing!
> My question to you is:  do you think it's possible to convert a ROWID field
> from Hexadecimal to a LONG datatype and then store the converted value in a
> field on the same table?
> 
> Cheers,
> 
> Rob Dunn
> Database Developer, Municipal Software
> Victoria, British Columibia
> Canada	V8N 1A6

I know that there are DBMS_ROWID procedures. For example,
DBMS_ROWID.ROWID_TO_RESTRICTED returns the rowid in ASCII format.

So, you can probably say:

UPDATE TABLE X SET LONG_COLUMN=DBMS_ROWID.ROWID_TO_RESTRICTED(ROWID,1);

Best regards,

-Ari Kaplan
Independent Oracle DBA Consultant

<-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><->
<-> For 345+ Oracle tips, visit my Web Page:                      <->
<->                                                               <->
<->             http://www.arikaplan.com                          <->
<->                                                               <->
<->             email: akaplan@interaccess.com                    <->
<-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><-><->

> 

Back to Ari Kaplan's Home Page

an's Home Page