Invalid hex number

Greetings PL/SQL Greats!
Can someone please tell me why I am getting "ORA-0464-Invalid hext number" error?
What is weird is after I executed my stored proc with one file, I get the file copied successfully from db to folder.
A second try succeeded as well.
After that, any other attempts to copy from db to folder resulted to error above.
I am having difficulty wrapping my head around this error.
Any help is greatly appreciated.
<pre><code>create or replace PROCEDURE Getblob(pfname VARCHAR2, display_name IN VARCHAR2)
IS
vblob BLOB;
vstart NUMBER := 1;
bytelen NUMBER := 32000;
len NUMBER;
my_vr RAW(32000);
x NUMBER;
v_name VARCHAR2(100);
lv_str_len NUMBER;
l_output utl_file.file_type;
BEGIN
-- define output directory
--lv_str_len := Length(pfname);
--v_name := display_name||upper(substr(pfname,lv_str_len-3,lv_str_len));
v_name := display_name;
l_output := utl_file.Fopen('/m705/gfile', v_name, 'w', 32760);
-- get length of blob
SELECT dbms_lob.Getlength(GFILE_BLOB_VALUE)
INTO len
FROM GFILE
WHERE file_name = pfname;
-- dbms_output.put_line('Length: '||len);
-- save blob length
x := len;
-- select blob into variable
SELECT GFILE_BLOB_VALUE
INTO vblob
FROM GBFILE
WHERE file_name = pfname;
-- if small enough for a single write
IF len < 32760 THEN
-- dbms_output.put_line('Single write ');
utl_file.Put_raw(l_output, vblob);
utl_file.Fflush(l_output);
ELSE -- write in pieces
-- dbms_output.put_line('multi write '||vstart);
vstart := 1;
WHILE vstart < len LOOP
dbms_lob.READ(vblob, bytelen, vstart, my_vr);
utl_file.Put_raw(l_output, my_vr);
utl_file.Fflush(l_output);
-- set the start position for the next cut
vstart := vstart + bytelen;
-- set the end position if less than 32000 bytes
x := x - bytelen;
IF x < 32000 THEN
bytelen := x;
END IF;
END LOOP;
END IF;
dbms_output.Put_line('End');
utl_file.Fclose(l_output);
EXCEPTION
WHEN OTHERS THEN
dbms_output.Put_line('ERROR');
END getblob;</code></pre>
Edited by: sonny on Nov 11, 2011 8:59 AM

I don't know what to tell you.
Other than to ask you to please tell me what you saw in the code that convinced you otherwise.
The one thing I would like to add was that after I executed the code twice, as indicated above, the users asked me if it was possible to grab all the files instead of grabbing the one file at a time as the code shows, I created a different stored proc that has rowid in the WHERE clause.
I ran the code and it got pretty much every file from the db.
Problem was that for some reason, it was changing the files to .txt file.
I decided to go back to using the code I posted above and that's when I started getting the invalid hex number error.
Does this make more sense?
Somehow, it seems to me, the code with the ROWID is still somewhere is interferring with this stored proc.
This purely a guess.

Similar Messages

  • Uploading a file into DB error occured: ORA-01465: invalid hex number

    While uploading a file into the DB, It is promting an error: "ORA-01465: invalid hex number"
    how to convert a binary data to hex format in this case.

    Hello again,
    Ok, to upload into the database through APEX, using the file browser, you need to do the following:
    1. Create the file browser item on your page.
    2. Create a page process that is executed on the SUBMIT button.
    The code should be something like this:
    IF ( :P1_FILE_NAME is not null ) THEN
      INSERT INTO oehr_file_subject(id,NAME, SUBJECT, BLOB_CONTENT, MIME_TYPE)
      SELECT ID,:P1_FILE_NAME,:P1_SUBJECT,blob_content,mime_type
         FROM APEX_APPLICATION_FILES
       WHERE name = :P1_FILE_NAME;
      DELETE from APEX_APPLICATION_FILES WHERE name = :P1_FILE_NAME;
    END IF;{size:14}Files uploaded through the file browser are inserted into APEX_APPLICATION_FILES and need to be copied into your file.
    Be sure to include a column in your table for the filename in {color:green}FILENAME.EXT{color} format so that the system will know how to handle the file when you try to download.
    {size}
    {size:14}
    Don.
    You can reward this reply by marking it as either Helpful or Correct :)
    {size}

  • ORA-01465:invalid hex number

    Hi,
    Insert into ur3users
    select user_id, pass_mgmnt.decrypt_pass(password), user_name from users ;
    ur3users.user _id (number 38,0)
    ur3user.user_name (varchar 100 byte)
    ur3users._password (varchar 100 byte)
    users.user _id (number 38,0)
    user.user_name (varchar 250 byte)
    users._password (varchar 250 byte)
    When I run the above query I get the following error:
    Error report:
    SQL Error: ORA-01465: invalid hex number
    01465. 00000 - "invalid hex number"
    When I run the select statement as stand alone, I have no issues.
    Possible causes and solutions?

    Hi,
    The problem probably lies in the function DECRYPT_PASS.
    Can you post the code behind it or is it sensible material?
    Some sample data would help as well.

  • ORA-01465: invalid hex number on form field having values like $0-$10k...

    Hi
    I have a form item (SPEND) of select list having values like
    $0 - $10k
    $10k - $50k
    $50k - $100k
    $100k - $250k
    $250k+
    For the new record, when I hit "SAVE” buttons it inserts the new records to the table with values ($0-$10k...)
    BUT when i edited the same record, and then try to "Apply Changes” getting following error message
    ORA-01465: invalid hex number
    Again when I change the value to null it simply allows the record to UPDATE.
    Again I changed the item to a text field i am getting same error when I try with charter (ABc...). BUT it allows to the number (123..)
    Column attribute is SPEND VARCHAR2 (15 BYTE)
    ie - when I try to update the SPEND field with the values ($0 - $10k,$10k - $50k,$50k - $100k,$100k - $250k,$250k+) I am getting above error message.
    ORA-01465: invalid hex number
    Environment:
    Oracle Apex- 4.1
    DB-11g
    Thanks,
    Amu
    Edited by: Amuly on Jul 16, 2012 5:00 PM

    Use utl_raw.cast_to_raw() function when you convert HEX value into RAW(), e.g.:
    SQL> create table ztest (ff raw(1000));
    Table created
    SQL> insert into ztest (ff) values
      2  (utl_raw.cast_to_raw('596F75207765726520646973636F6E6E65637465642066 726 F 6D207468652041494D207365727669996365207768656E20796F752073696
      3  76E656420696E2066726F6D20616E6F74686572206C6F636174'));
    1 row inserted

  • Receiving ORA-01465: invalid hex number when using HEXTORAW

    I'm trying to use hextoraw to convert a value in a CSV file read from an external table. Works on some systems and not on others. Is there a way that I can avoid this or program around this? Any ideas what the problem is? It fails with an “invalid hex value” .
    This is for Oracle 10.2.0.4 Here is the code and the external table that I’m using.
    select HEXTORAW(REPLACE(EnkryptedPassword,'0x')) FROM CUSTOMER1; <--- Failes or ORA-01465 (CSV file data below)
    CREATE TABLE CUSTOMER1
    UserID VARCHAR2(100 CHAR),
    FirstName VARCHAR2(50 CHAR),
    LastName VARCHAR2(50 CHAR),
    Locked VARCHAR2(50 CHAR),
    CustomerID VARCHAR2(100 CHAR),
    Pwd VARCHAR2(100 CHAR),
    EnkryptedPassword VARCHAR2(100 CHAR)
    ORGANIZATION external
    TYPE ORACLE_LOADER
    DEFAULT DIRECTORY ARCHIVE
    ACCESS PARAMETERS
    RECORDS DELIMITED BY NEWLINE
    FIELDS TERMINATED BY ","
    MISSING FIELD VALUES ARE NULL
    LOCATION ('PWDCONVERSION2')
    REJECT LIMIT 1
    COMMIT
    Inside the PWDCONVERSION2 file:
    [email protected],JOHN,SMITH,1,C_2M8C2F_CM_NC,C_2M8C2F_CM_NC,0x7C4141938A1F69944BFCA0BED5BB3FEA3CA92A7

    Thank-you for the response. I believe I may have found the problem (probably).
    On some systems the ACCESS PARAMETER for the external table "RECODRDS DELIMITED BY NEWLINE" will not work if there is some other character other than "\n". In windows it works fine. On some other systems it works finds as well. On Linux Distro I tend to run into problems. I tried this out for more than one line in the CSV. Then scaled back to just one line. It accepted one line but not more than one line. So I trying
    RECORDS DELIMITED BY NEWLINE CHARACTERSET WE8MSWIN1252
    Any ideas what would help recognize all types of newline characters?

  • How do I convert an array of BYTES (where each BYTE represents a bit) into a single Hex number?

    I am reading a signal from a USB-8451. This signal is stored as an array where each element represents a bit in the signal, but is stored in the array as a byte. How do I convert this array into a single Hex number. I attatched what I have so far, there are a few extra things to help me see what ia going on. One code uses Queue and the other uses arrays, let me know if you can help.
    Attachments:
    845x_EEPROMarrays.vi ‏27 KB
    845x_EEPROM.vi ‏26 KB

    mkssnwbrd wrote:
    ... so we can't introduce any other forms of signals or power into the circuit other than what the circuit already has. Trithfully I don't really know how I2C devices work, but my mentor here says that we can't use an I2C method becuase it will introduce voltage into the circuit and may damage out TCON chip.
    That makes absolutely no sense. What do you think is happening when you write the digital lines? You're setting a pin high. That voltage is being generated by the 8451x. I think you're not understanding what your mentor is saying. If it's an I2C device then you should be able to use the I2C function to simply talk to it. You still have not indicated what the device is, so there's little more I can say about that aspect of it.
    As far as the conversion is concerned, you basically need loop through your array of "bits", taking 16 at time since you said you have 16-bit values. It's not clear from your code whether your eventual goal is to get a numeric value or a string. This does not appear to be a subVI, so a simply numeric indicator formatted to display in hex format should be quite adequate. The array you are generating is an array of rings, whose datatype is I32, but they will have values of 0 or 1. You can use the example just posted, or you can use the attached variation.
    Attachments:
    Bits to Hex 2.vi ‏17 KB

  • How can I convert an ASCII string of variable length to a HEX number?

    Hello,
    I read data from the serial port 5 times in a second (while loop) and the number of bytes read varies every time.
    The data comes in as ASCII string, and I can see the HEX representation if I connect a HEX string indicator, but I need to permanently convert data to a HEX number. 
    How can that be done?

    Like This.
    Ton
    Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
    Nederlandse LabVIEW user groep www.lvug.nl
    My LabVIEW Ideas
    LabVIEW, programming like it should be!

  • Invalid Serial Number for Photoshop CS6

    We tried to download the software with the serial number, however fail. It prompts the following error message
    “Invalid Serial Number” Please re-enter a valid serial number.
    Please advise us a solution.

    Where did you buy it?  Where did you download it from?
    How many digits are in the serial number you are trying to use?
    You should know that you are NOT addressing Adobe here in these user-to-user forums,

  • Acrobat XI Invalid Serial Number After Failed Install

    Hello,
       We currently have Adobe Acrobat XI on an enterprise license. I went to install this on 3 of our Windows 7 tablets. Prior to my attempt, I removed Adobe Reader XI which is what I always do. After that I started the installer on the machine and entered the key just fine. All 3 tablets got stuck around 96-97% and failed with an error 1935. I then followed the instructions located here:
    https://helpx.adobe.com/acrobat/kb/error-1935-install-acrobat-reader.html
      Following a reboot, I tried to install again and now I am receiving the "Invalid Serial Number" error when trying to click "Next" on the installer. It won't even let me choose install trial and go. The next button does nothing when selecting trial. I tried running the offical Adobe Acrobat Cleaner and the Adobe CS6 cleaner (since Acrobat XI is part of CS6 technically). Both programs found items to delete but following a reboot I'm still receiving the same error. I also have other XI enterprise serials available and none of them work. I have a feeling something happened on the tablets that is causing the installer to think it's the wrong version or type for those serial numbers.
      Any assistance is greatly appreciated.

    Hi Rosa,
    I would like to check the issue at your end.
    Can you please provide me the contact details at [email protected] so that we can discuss this on call.
    Regards,
    Rave

  • Invalid serial number error message when installing Acrobat 7

    I have my original software CD and serial number but understand that I need to use the downloaded program because Adobe no longer supports the activation code required for installing from the disc.  I was under the impression that I was to use the original serial number.  This is what I used when reinstalling my CS2 Photoshop  in the same circumstances.
    I downloaded 22001904.exe and ran it but when it gets to the serial number I receive invalid serial number message no matter how I enter the number.  I even tried cutting and pasting from my Adobe profile, since I have registered the program w/ Adobe previously along with other Adobe programs.
    Can you advise me how to proceed? 
    Sincerely,
    brokripananda

    no, use the serial number listed on the page where you downloaded acrobat 7, not your acrobat serial number

  • I have the appropriate Adobe Acrobat 9 Standard software and a valid SN for that software; however, am getting an "Invalid Serial Number" error on installation...please help

    I have the appropriate Adobe Acrobat 9 Standard software and a valid SN for that software; however, am getting an "Invalid Serial Number" error on installation...please help

    Hi James ,
    Make sure you are entering the correct serial number.Try it once again and check.
    If it fails please get in touch with Adobe Support.Here is the link for the same.
    https://helpx.adobe.com/adobe-connect/kb/connect-chat-support.html
    Regards
    Sukrit Dhingra

  • Had to buy a new laptop and am trying to install XI (current and active licensee)....registration setup screen indicates ("Invalid Serial Number")

    had to buy a new laptop and am trying to install XI (current and active licensee)....registration setup screen indicates ("Invalid Serial Number")? Account is active.

    Is it by any chance asking for a "qualifying serial number"?

  • Reinstalling FCP7 in my new Macbook Pro Retina Display. I have my serial numbers back to FCP1. But it tells me that I have an invalid serial number.  Why?

    Reinstalling FCP in new Macbook Pro Retina from time machine backup.  Have all serial numbers back to FCP1 but I am warned I have an invalid serial number.  How can that be!  I need to install and use this weekend.
    Thank you in advance for the help.

    How, exactly are you doing this?
    When I restored  my new computer from the time machine, the software was transfer to the new machine, in the past when double clicking the icon it would come up and ask for the serial numbers.  This time was the same with the exception of:
    I did not enter an invalid serial number, I tried all the numbers I have.  But none of them worked.
    I will try to install from discs.
    Thanks for your help.

  • Adobe Acrobat 7.0 - invalid serial number

    I have a new computer so I tried to install Acrobat Pro 7.0 on my new computer but received a message saying it is an invalid serial number. I got the serial number from my products under my adobe id. Please help! I need my adobe acrobat pro on my new computer!!

    You need to get a special version along with a special serial number.  See the following...
    CS2: Error: Activation Server Unavailable | CS2, Acrobat 7, Audition 3 -
    http://helpx.adobe.com/x-productkb/policy-pricing/creative-suite-2-activation-end-life.htm l 
    https://helpx.adobe.com/creative-suite/kb/cs2-product-downloads.html

  • Photoshop CS2- Invalid Serial Number

    I am installing my Adobe Photoshop CS2 on Windows Vista.
    When I try to install the program after entering my serial number that is on the CD case,
    the program states "Invalid Serial Number."
    Customer Service gave me new serial numbers to attempt at fixing this issue and those numbers still yielded an "Invalid Serial Number" error.
    Tech Support had me create new accounts with admin rights on my laptop (which didn't work) and then gave me a link
    about the issue that had nothing to do with me since I have no VCOM software on my laptop (so that too was bogus).
    I requested to speak to a manager where the agent diverted with giving me solutions that did not work also in which
    he had me use this registry cleaner software and it still didn't work (I didn't have previous adobe software on my computer,
    so it wasn't a surprise that it didn't work)
    So... Does anyone know how I can install my program on my laptop without getting an Invalid Serial Number error?????
    Maybe regular users have some answers.

    I've only had similar happen once, when I upgraded AI over about 3-4 versions. My S/N was from the first PC release, and the internal database in the upgrade did not recognize the format, or the S/N. In that case, a 5 min. call to C/S resulted in a number to enter from Adobe, and then it took my S/N fine.
    Obviously, you've gone that route, and it's not working. Seems that things have changed with C/S, but I am talking over a decade ago. Are you talking to C/S (Customer Service), or T/S (Technical Service)? For "sales" related things, I have found that C/S is the better. I am assuming that they are still separate departments, though both might well be in India.
    Now, one question, you say that C/S told you to run on one machine with "administrative rights." Did you try as an Administrator? These are similar, but there can be differences.
    Wish I had something else to offer.
    Good luck,
    Hunt

Maybe you are looking for

  • How do I recover data after update from iOS 4to iOS 7

    I just spent several hours making a backup of an iPhone 4S working on iOS 4 before upgrading to iOS 7 in order to use a specific APP. After the upgrade and restoring the backup I have lost all my old apps and associated data. I am sorely tempted to c

  • ODBC connect from Oracle to MySQL!

    Dear All, I know its not very much related to the subject of this forum but DBA's often have to perform such tasks. I am in process of developing replication between Oracle and MySQL. For this I have planned to create materialized views in oracle tha

  • Updater 2005-10-12: Downloaded but not running

    Guys & Girls, bear with me on this... I have been stuck with this issue for a few weeks now and originally had raised this issue on the ITunes forum and despite 30 or so postings nobody solved this problem. Basically I can download the updater for th

  • SUNWasac as a service in SMF.

    I performed a full install of Solaris 10 and I find that the "Sun Java System Application Server v8.2" is included in the distribution. As I have a need to use this it is convenient (as opposed to bloaty which might be another's opinion of the inclus

  • Trouble implementing a header on Wordpress

    I installed the Edge Suite Plugin. I used the shortcode to successfully implement my animation I created for my about me page. I now want to implement a header I created for my site. I uploaded the animation witth the .oam file and chose it as my "de