Transfer of records

I need some recored to be transfers
and my procedures take care of it.. now if there is an errors the counter bumps upp..
What my problem is that. the ocunter bumps up for just one record and it is not going on to the second record.. insed it exits..
I believe there is a prblem in the Exception hadeling section.. If soem can helo me figure out.. how I can write it soo it will go on to the other records bump up the counter if necessary..
followin is my Procedure
Create or Replace Procedure appmstansfer IS
Cursor C1 is
Select * from appms_mri_errors;
lv_cntr Number(2);
err_code_current NUMBER := SQLCODE;
err_msg_current VARCHAR2(60):= SUBSTR(SQLERRM,1,60);
insert_failure Exception;
lv_val appms_mri_errors.barcode%type;
lv_new_val appms_mri_errors.barcode%type;
lv_err_record Number(4);
Begin
Select count (*)
Into lv_err_record
from appms_mri_errors;
If lv_err_record > 0 then
For my_rec in C1
Loop
DBMS_OUTPUT.PUT_LINE('1');
lv_val := my_rec.barcode;
Insert into appmslog
(ROWSTAMP, KEYNUM, ERRORMSG, DESCRIPTION, TRANSDATE, STATUS,
STATUSDATE, BARCODE, FOA, HRHNUM, HRHNAME, CHANGEBY,
CHANGEDATE, NSN, ACQDATE, ACQCOST, DISPOSITIONCODE,
SERIALNUM, LOCATION, ROOMNUM, PRNUM, VENDOR,
MANUFACTURER, PARTNUM, MODELNUM, ECC, EIC, EUMPCODE,
APPMSLOG01, APPMSLOG02, APPMSLOG03, APPMSLOG04,
APPMSLOG05, APPMSLOG06, APPMSLOG07, APPMSLOG08,
APPMSLOG09, APPMSLOG10, LDKEY)
Values
(my_rec.ROWSTAMP, my_rec.KEYNUM, my_rec.ERRORMSG,
my_rec.DESCRIPTION, my_rec.TRANSDATE, my_rec.STATUS,
my_rec.STATUSDATE, my_rec.BARCODE, my_rec.FOA,
my_rec.HRHNUM, my_rec.HRHNAME, my_rec.CHANGEBY,
my_rec.CHANGEDATE, my_rec.NSN, my_rec.ACQDATE,
1200000000000, my_rec.DISPOSITIONCODE,
my_rec.SERIALNUM, my_rec.LOCATION, my_rec.ROOMNUM,
my_rec.PRNUM, my_rec.VENDOR, my_rec.MANUFACTURER,
my_rec.PARTNUM, my_rec.MODELNUM, my_rec.ECC,
my_rec.EIC, my_rec.EUMPCODE, my_rec.APPMSLOG01,
my_rec.APPMSLOG02, my_rec.APPMSLOG03, my_rec.APPMSLOG04,
my_rec.APPMSLOG05, my_rec.APPMSLOG06,
my_rec.APPMSLOG07, my_rec.APPMSLOG08, my_rec.APPMSLOG09,
my_rec.APPMSLOG10, my_rec.LDKEY);
Commit;
Select barcode
Into lv_new_val
from appmslog
where barcode = my_rec.barcode;
If lv_new_val = my_rec.barcode then
Delete from appms_mri_errors
where barcode = lv_new_val;
Else
raise insert_failure;
End if;
DBMS_OUTPUT.PUT_LINE('2');
Commit;
End Loop;
end if;
EXCEPTION
WHEN insert_failure then
Select reconcile_attempt_cntr
Into lv_cntr
from appms_mri_errors
where barcode = lv_val;
Update appms_mri_errors
Set
Error_Code_Current = err_code_current,
Error_Text_Current = err_msg_current,
Reconcile_Attempt_CNTR = lv_cntr + 1,
Failuredate_Current = Sysdate
where barcode = lv_val;
When others then
Select reconcile_attempt_cntr
Into lv_cntr
from appms_mri_errors
where barcode = lv_val;
Update appms_mri_errors
Set
Error_Code_Current = err_code_current,
Error_Text_Current = err_msg_current,
Reconcile_Attempt_CNTR = lv_cntr + 1,
Failuredate_Current = Sysdate
where barcode = lv_val;
DBMS_OUTPUT.PUT_LINE('3');
Commit;
END;

After a procedure goes to the exception section, the block terminates. It will not resume processing the cursor within your loop. So, try to handle everything that you can within the loop. For example, to move the insert_failure from the exception section to within the loop:
Create or Replace Procedure appmstansfer
IS
Cursor C1
is
Select *
from appms_mri_errors;
lv_cntr Number(2);
err_code_current NUMBER := SQLCODE;
err_msg_current VARCHAR2(60) := SUBSTR(SQLERRM,1,60);
lv_val appms_mri_errors.barcode%type;
lv_new_val appms_mri_errors.barcode%type;
lv_err_record Number(4);
Begin
Select count (*)
Into lv_err_record
from appms_mri_errors;
If lv_err_record > 0
then
For my_rec in C1
Loop
DBMS_OUTPUT.PUT_LINE('1');
lv_val := my_rec.barcode;
Insert into appmslog
(ROWSTAMP, KEYNUM, ERRORMSG, DESCRIPTION, TRANSDATE, STATUS,
STATUSDATE, BARCODE, FOA, HRHNUM, HRHNAME, CHANGEBY,
CHANGEDATE, NSN, ACQDATE, ACQCOST, DISPOSITIONCODE,
SERIALNUM, LOCATION, ROOMNUM, PRNUM, VENDOR,
MANUFACTURER, PARTNUM, MODELNUM, ECC, EIC, EUMPCODE,
APPMSLOG01, APPMSLOG02, APPMSLOG03, APPMSLOG04,
APPMSLOG05, APPMSLOG06, APPMSLOG07, APPMSLOG08,
APPMSLOG09, APPMSLOG10, LDKEY)
Values
(my_rec.ROWSTAMP, my_rec.KEYNUM, my_rec.ERRORMSG,
my_rec.DESCRIPTION, my_rec.TRANSDATE, my_rec.STATUS,
my_rec.STATUSDATE, my_rec.BARCODE, my_rec.FOA,
my_rec.HRHNUM, my_rec.HRHNAME, my_rec.CHANGEBY,
my_rec.CHANGEDATE, my_rec.NSN, my_rec.ACQDATE,
1200000000000, my_rec.DISPOSITIONCODE,
my_rec.SERIALNUM, my_rec.LOCATION, my_rec.ROOMNUM,
my_rec.PRNUM, my_rec.VENDOR, my_rec.MANUFACTURER,
my_rec.PARTNUM, my_rec.MODELNUM, my_rec.ECC,
my_rec.EIC, my_rec.EUMPCODE, my_rec.APPMSLOG01,
my_rec.APPMSLOG02, my_rec.APPMSLOG03, my_rec.APPMSLOG04,
my_rec.APPMSLOG05, my_rec.APPMSLOG06,
my_rec.APPMSLOG07, my_rec.APPMSLOG08, my_rec.APPMSLOG09,
my_rec.APPMSLOG10, my_rec.LDKEY);
Commit;
Select barcode
Into lv_new_val
from appmslog
where barcode = my_rec.barcode;
If lv_new_val = my_rec.barcode
then
Delete from appms_mri_errors
where barcode = lv_new_val;
Else
Select reconcile_attempt_cntr
Into lv_cntr
from appms_mri_errors
where barcode = lv_val;
Update appms_mri_errors
Set Error_Code_Current = err_code_current,
Error_Text_Current = err_msg_current,
Reconcile_Attempt_CNTR = lv_cntr + 1,
Failuredate_Current = Sysdate
where barcode = lv_val;
End if;
DBMS_OUTPUT.PUT_LINE('2');
Commit;
End Loop;
end if;
EXCEPTION
When others then
Select reconcile_attempt_cntr
Into lv_cntr
from appms_mri_errors
where barcode = lv_val;
Update appms_mri_errors
Set Error_Code_Current = err_code_current,
Error_Text_Current = err_msg_current,
Reconcile_Attempt_CNTR = lv_cntr + 1,
Failuredate_Current = Sysdate
where barcode = lv_val;
DBMS_OUTPUT.PUT_LINE('3');
Commit;
END;
null

Similar Messages

  • I have a digital voice recorder with a 3.5mm mic and headphone jack and want to transfer some recorded lecture to my mac book pro.  The mac book does not have 3.5mm  jacks.  Does anyone know if a jack to USB converter would work?

    I have a digital voice recorder with a 3.5mm microphone and headphone jack and want to transfer some recorded lectures to my mac book pro.  The mac book does not have 3.5mm  jacks.  Does anyone know if a jack to USB converter would work?

    Is there a pattern to the time of day or other detail that may be
    traced back to a OS X system cause of this odd phenomenon?
    Are there any copies of system files on any of the attached USB
    external drives? Any libraries, such as iTunes, iPhoto, etc?
    Once the drives are indexed by Spotlight, are their permissions
    ignored by the OS X? Content, if neutral, should not affect the
    wake or sleep cycle; especially if they're ignored by the OS X.
    Could there be a bad cable or other component? If so that would
    be a difficult process of elimination to detect it. Usually replacing
    most suspect components in the USB stream (external to Macs)
    is a rote way to mechanically test that idea; & not 100% sure.
    Does the equipment all have a good ground to the utility or house
    electrical field? An intermittent ground may affect more than sleep.
    Hard to say at this point. Maybe a late-night talk radio guru on
    remote viewing could peer into your situation and sleuth it out?
    Sorry to have run out of ideas, but the process must be electrical
    & mechanical to some extent. - Or perhaps odd software inspired.
    Do you have any phone-home spyware items inside, just jumping
    at the chance to spill your information? Little Snitch may help.
    PS: Perhaps the computer needs to go into Apple & have a genius
    or product specialist at AASP test the unit thoroughly... BlueTooth?
    see:
    https://www.google.com/?gws_rd=ssl#q=Wake+reason:+XHC1
    Good luck & happy computing!
    edited 2x

  • How to transfer my recorded audio to my PC?

    Dear Sir/Madam,
    I was recorded some sound through iPhone. It is the way to transfer the recorded audio via MMS/Email. But I don't want to use it.
    Do you have another way to copy the recorded audio to my PC?
    Thanks for your help!

    ilikeike, Welcome to the discussion area!
    You can use a USB audio input device like the iMic.

  • Transfer vendor records

    Hi Friends,
    I tried to transfer vendor records (BBPGETVD) from R3 to SRM, we use external range for R3 vendors. Some vendor records were transferred successfully, but some not. I have no system errors but vendor records not transfer to SRM.
    Do you know the reason?

    Hello Marina, do you transfer vendors with right parameters? please check if you put in vendors from and purchasing organization fields that not corresponds with values that you want to transfer....
    Thanks
    Rosa

  • Transfer price records for materials

    \We have activated transfer pricing for profit centres.  However, all materials transfer between profit centres are not subject to transfer pricing. 
    But while doing any strock transfer between plants & profit centres of materials, system is error messaging that no transfer price records are maintained.  It is obviously not possible to maintain price records for all materials which may be around 4000.  What is the way out ?

    hi..
    Goto Profit Centre Accounting > Tools > Customer Enhancement > Develop Enhance for PCA
    Here you will find
    Document changes for data transfer (PCA00001)
    Assignment of a representative material (PCA00002)
    Determination of transfer prices (PCATP001)
    Enhancement in the authorization check (PCAAUTHO)
    Change to selection criteria for data transfer (PCASELEK)
    For additional information about this enhancement, see Choose Actitvies for Exit PCASELEK
    Apply as per your requirement.
    kkumar

  • If i transfer some records from one server to another server,

    hi to all......
    5........If i transfer some records from one server to another server, will that save in change request or work bench request?
    thanks and regards,
    k.swaminath

    Hi friend my suugession is , if u r transfering records from one client to another or changing anything in the active pgm, it will save under  change request...
    But if u r transfering records from one server to server it will save under work bench request...

  • Transfer BDC recording between two clients?

    Hi all,
    I have a BDC recording in one client and I need to transfer this recording to another development client. How can I achieve this? Is there any standard tcode for the same as we do in transfering SAP scripts? Please guide.
    Regards,
    Anu.

    Hi Anu,
    There is no Standard Tcode but after saying your recording How will save in program in the same way do there and upload the program in wht client You need. or copy and past.
    regards,
    sg

  • HT2929 How do I transfer vinyl recorded on a PC to iTunes?

    How do I transfer vinyl recorded on a PC to iTunes?

    What format was it recorded on?  Wav? MP3? 
    If so, just use the Add File To Library or Add folder to Library options in iTunes File Menu.
    iTunes: About the Add to Library, Import, and Convert functions - Apple Support

  • Transfer audio recording from quickvoice to computer

    I need to transfer some conference recordings done in Quickvoice on my iPhone4 to my computer & do not see the info for assistance.

    I had a similar problem with an external microphone that didn't need power supply. I checked the source on the sound of the system preferences, and whenever I had the microphone attached, no sound was being input, only sound picked up when I had the internal microphone selected.
    This summer for a class project, I thought it was picking up sound while I was recording a movie, using iSight, and when i finished, all i had was the video with no audio. Then I had to re-do the class project.
    Did your problem ever get resolved? If so, what did you end up doing to resolve it?

  • For Init without data transfer showing records 0 from 0

    Hi all,
    Iam doing Init without data transfer to ODS. In the ODS manage it is showing 1 from 1 which is correct. This ODS data is automatically updated to a cube. There in the cube manage it is showing 0 from 0. My mappings in update rules also correct , but why it is not giving 1 from 1.
      In the cube manage the status is showing green but in the monitor of cube always it is yellow.
    Help me please
    Ram

    Hi Ram
    If you load data with INIT without data transfer then system shows the defualt record in the monitor.
    If check that record in the PSA then you dont find it and on the cube as well.
    If the load is green with 1 record then extractor working fine.It's not actaully a data reocrd.
    Hope it helps...
    Regards,
    Chama.

  • How can I transfer large recording I made from iPad to my computer

    I recorded 2 videos on my iPad that about 1-1/2 hours long each but I can't seem to get it to transfer to my computer so I can make a DVD.  What do I need to do?  I need Help

    Hello
    I am Rich1108.
    I have the same problem you have with a large 52 min video on my ipad that all of the PC file managers do not see, even though they see all of the other videos on my ipad.  I have tried importing etc., and I always just get everything except the large file in question.  I have a 13 GB (16-used elsewhere?) ipad, and I believe that the 52 min movie takes all but 700 MB of my 13 GB.
    An associate at the Apple store near me told me to try Kodac EasyShare instead of the windows applications, but I don't think that is a good answer.  I have not tried it because one of my old computers uses a Kodac application to offload pictures from an old camera, and that is not a good application.  (It works, but is slow and does not really provide me with anything I can't do better with Windows Explorer.  And I don't like the way it works).
    But that is my only option right now.  I got a reply from Texas Mac Man, but he only referred me to standard methods.  He does not seem to understand that this large video defies the usual methods.  I did find a place where it was stated that the Import feature can only get files up to 500 Megabytes.  I have reason to believe that my video is about 12 GB.
    By the way, you probably have found that you also cannot trim your large video.  It seems that the ipad looks at the size and balks at that.  Mine says it can't trim because the file is too big.  That is before it even asks me if I want to trim the original or create a new sub-video.  But you might try trimming your video into smaller parts if your ipad will let you do that.  I think the import problem definitely has something to do with the size of the video.  You could always put the video back together again with a decent movie application.  (I use the one that comes free with Windows 7 called Microsoft Movie Maker or somehting like that.)  But unfortunately most of my valuable ipad movies were taken so that they show up upsidedown on most viewing applications, except the ipad.  There is probably an application that will fix that, but I have not found it yet.
    Please let me know if you find a solution to this large video problem.  I need to free up space on my ipad if nothing else, so I can't wait too long to delete this 52 min thing from the ipad.
    Thanks
    Rich1108

  • Need to transfer data records from one version of sap to another version of

    hello,
            i have a requirement where i need to transfer the tables  with the records in it from sap r/3 4.7 version to sap ecc 6.0 version,now the present issue is how to tranfer the data records from old version to new version......kindly help me in this requirement

    Hi,
        Write a program in SAP 4.7 to download all records to a flat file. Then write a program in ECC6 to upload all records from the flat file...........
    Thanks,
    Aditya.

  • Function modules transfer  repeated records in Generic data source

    Hello Friends ,
    I have created a FM to extract the data from fields of  tables BKPF and BSEG .
    This functional module is used in the Generic data source.
    Now if I check in RSA3 for this Generic data source,
    the records are coming 10 times instead of a single time.
    Means one records at data base table is showing ten records in RSA3.
    Any help please.
    Regards,
    Amol.

    Hi Amol,
      Can you please check the Fetch statement that you are using after opening the cursor and selecting data into it. It should be in the format below.
    FETCH NEXT CURSOR S_CURSOR APPENDING CORRESPONDING FIELDS OF TABLE                                                 E_T_DATA PACKAGE SIZE S_S_IF-MAXSIZE.
    Also are you incrementing data package ID or not by using the statement  
    S_COUNTER_DATAPAKID = S_COUNTER_DATAPAKID + 1.
    Regards,
    Prakash B

  • How do I transfer a recording from Smart Record Lite to my Imac?

    I have recordings made with the Smart Record Lite App.  They are on my ipad and ipod.  how do I go about transferring them to my iMac so I can upload them to You Tube?

    http://www.roemobiledevelopment.com/Site/Smart_Recorder.html
    If you need more information or assistance, you probably should contact the developer of the app.
    Regards.

  • Transfer camcorder recorded video to iPad?

    I like taking video with my Canon HF M56 to freeze the sweet memory wherever I go. Recently I tried to transfer some videos from the camcorder's memory to my new ipad air through my mac mini, I always failed with the error "video format incompatibility". How could I solve this problem? I do not want to sacrifice any video quality. Thanks!

    YOu can use some free converters to help you.: Handbrake, MPEG Streamclip, ffMPEG. 
    Or even you can use VLC player! I find this player can play your mts files wihtout any rewarpping and you can convert your files into MP4 if you want. Awesome , right?
    But to tell you the truth , if you want to keep the high definition of your videos, that may be a little difficult by those free apps. So I am considering update my free mts/m2ts converter from pav to the full one.

Maybe you are looking for