Wallet - without SSO File

Hello
I'd create a oracle wallet and i can connect without a password to the database. But now I'd delete the sso-file because I'll open the wallet with the statment "alter system.....". But I can't connect now als sys or system user. (Connect / as sysdba). I get always the message: "TNS: Wallet open failed".
What's wrong?
Thanks....
roger
Edited by: Street on 13.04.2012 01:45

Hi Roger,
you moust change sqlnet.ora. Disable wallet lines.
FJH
Sorry I did not read exactly. Above reply is invalid.
FJH
Edited by: user8684352 on 17.04.2012 04:49

Similar Messages

  • HT3523 I can play an .mov file but cannot open it to move it to another drive/disc/etc. When we try to open it, we get a message that says "The movie file for "beanmine.mov" cannot be found. Without this file, the movie cannot play properly."

    We can play a .mov file (a full-length film created in final cut pro) but cannot actually open it in QuickTime. We get the error message saying that a file is missing, and the movie can't play properly without the file. The thing is, we can play the film, we just can't open it to move it to another drive. Help?
    Also, can the lost file (which was deleted) be recovered from a Mac HD or an external hard drive?
    Help!

    We can play a .mov file (a full-length film created in final cut pro) but cannot actually open it in QuickTime. We get the error message saying that a file is missing, and the movie can't play properly without the file. The thing is, we can play the film, we just can't open it to move it to another drive. Help?
    Sounds like you created a "Reference" file here. I.e., a "Reference" file is a file that tells the player how to play the data contained in a "Resource" file. When you try to open the "Reference" file in the QT Player app, the first thing the player does is check to see if the "Resource" data file is is still available where it is supposed to be. (I.e., moving/deleting the resource file or moving reference file without moving the resource file to maintain the relative path between the two will generate the error message you mentioned.)
    Also, can the lost file (which was deleted) be recovered from a Mac HD or an external hard drive?
    That depends. Deleting a file does not actually erase the data immediately. Instead, the operating system just tells the system directory that the space containing the movie data is available for reuse if/when needed. As time passes, the chance that some of the data sectors will be re-written by other data continuously increases. To restore the file normally requires use of a special utility that both locates and restores all of the linked sectors containing the "deleted" movie data in their correct order. Other methods of restoring files would depend on the software you routinely have active on your system. For instance, do you use "TimeMachine?" or orther software that automatically backs up your data periodically? If so, then follow the instructions for your particular application to recover a deleted file.

  • I have an external server that stores all my movies and music, is there a way to stream it to my apple tv? If not is there a way I can link the folders to itunes (without downloading files to computer) and will that make them view-able for the apple TV?

    I have an external server that stores all my movies and music, is there a way to stream it to my apple tv?
    If not is there a way I can link the folders to itunes (without downloading files to computer) that will make them view-able for the apple TV?
    If none of that works is there a way to get it working alternativly?
    Additional Information:
    Everything is linked via ethernet cable.
    I'm using a PC to set it up.
    If you have any other questions feel free to ask and I'll help where I can.
    Thank you for any help

    (I think the daughter got he better end of the deal!)   I believe if you change the password and user id one of the devices it will stop that from occurring. But I'm not the one to tell you how to do it; someone like "Illaass" (Illaass seems to know how to correct / fix almost anything!) will know how if you don't. Just look for the "cat" icon.

  • How can I insert a number of photos in a numbers doc without the file becoming too large?

    How can I insert a number of photos into a numbers doc without the file becoming too large?

    Use smaller photos.
    Seriously, reduce the file size of the photos in Preview, PhotoShop, iPhoto or other application before inserting tehem into the Numbers document.
    Regards,
    Barry

  • How to share iMovie library with other accounts without duplicating files?

    I'm looking for information on how to share an imovie library with other accounts on the same computer without duplicating files.  If I  copy imovie files to the shared folder each user is required to import the files to their library which duplicates the files.  It would be nice if imovie had the option of including events/projects shared in the share folder.  Is there an option to change everyone's default library to a shared folder?  Any help would be appreciated.
    Thank you!

    The easiest way to do this would be to atach an external drive. The external drive should be formatted as Mac OS Extended (journaled). If you have a drive that is formatted some other way, you can reformat it using Disk Utility. It can be Thunderbolt, Firewire, or USB, but Firewire or Thunderbolt will give best performance for video.
    Now you need to move the projects and events over to the external drive. This must be done from within iMovie.
    In iMovie, click VIEW/EVENTS BY DISK.
    Now, in the Project Library View, hold down the command key while dragging the small icon for each project to the small icon for the external drive. Now select one of these projects and click FILE/CONSOLIDATE MEDIA. This will enable you to move associated Events, Photos, and Music to the external drive. Repeat for all projects.
    If any events are left over at the end of this, because they are not used in any of your projects, you can move them to the external drive by working in the Event Library list. Hold down the Command Key while dragging the small icon for the Event in the Event Library List to the small icon for the External Drive. Repeat until all the Events are moved.
    Now you can edit these movies on any user account.
    For future clips that you import from a camera, be sure to select the external drive as the location.

  • How to add a record in document library without upload file.

    Hi,
    how to add a record in document library without upload file?
    Is it possible? I want to create a folders in Document Library but inside folders i do not want to upload a file instead of just i want to create a record. I will map my local file path to the records.
    Can anyone help me on it?
    Thanks & Regards
    Poomani Sankaran

    Hello Sankaran,
    document library is to upload documents, without document you will not be able to add a record or Item to it.
    for your requirement you can use a list and enable folders within the list and maintain the local path of the file as an item in list.
    http://www.sharepointbriefing.com/spconfig/article.php/3834951/Enable-the-New-Folder-Creation-Option-in-SharePoint-Custom-Lists.htm
    My Blog- http://www.sharepoint-journey.com|
    If a post answers your question, please click Mark As Answer on that post and Vote as Helpful

  • I want to start a new movie but iMovie is hung looking for an old file and says:"Without this file, the movie cannot play properly."

    Hello!
    I recently upgraded to Lion. Every time I start up iMovie, it asks if I want to go ahead and generate thumbnails. I say OK, then it alerts me that it cannot file the file IMG_0073.MOV. Then it says "Without this file, the movie cannot play properly." It gives me the option to either cancel or search for the movie.
    I don't have the old file it's looking for. I simply want to start a fresh movie with new material but cannot get past this hump. Based on the little research I have done, some people experienced this problem because the files were in aperture at some point, which was the case for me before when I used iMovie. I have since moved forward only with iPhoto but perhaps it's hung on an old file format?
    I tried taking another old movie and renamed it IMG_0073.mov to see if I could simply select it, give it what it wants and move on but it won't let me select the file for some reason. I also tried removing iMovie and downloading a fresh version but that didn't work either. My BF tried removing pfiles (I think that's what it's called? but again no luck)
    Please help! I must get this assignment done for a class!

    Hello!
    I recently upgraded to Lion. Every time I start up iMovie, it asks if I want to go ahead and generate thumbnails. I say OK, then it alerts me that it cannot file the file IMG_0073.MOV. Then it says "Without this file, the movie cannot play properly." It gives me the option to either cancel or search for the movie.
    I don't have the old file it's looking for. I simply want to start a fresh movie with new material but cannot get past this hump. Based on the little research I have done, some people experienced this problem because the files were in aperture at some point, which was the case for me before when I used iMovie. I have since moved forward only with iPhoto but perhaps it's hung on an old file format?
    I tried taking another old movie and renamed it IMG_0073.mov to see if I could simply select it, give it what it wants and move on but it won't let me select the file for some reason. I also tried removing iMovie and downloading a fresh version but that didn't work either. My BF tried removing pfiles (I think that's what it's called? but again no luck)
    Please help! I must get this assignment done for a class!

  • Is there a way I can use my external hard drive without the files being transferred on to my computer? as like like my iTunes music being on my hard drive without them being copied onto my computers hard drive ?

    is there a way I can use my external hard drive without the files being transferred on to my computer? as like like my iTunes music being on my hard drive without them being copied onto my computers hard drive ? because i dont have that much memory and i wanted my external hard drive to be the source for my music files and not my computer.

    Many users keep their iTunes libraries on external drives. You just have to remember to connect and power up the drive before launching iTunes.
    iTunes for Mac: Moving your iTunes Media folder:
      http://support.apple.com/kb/HT1449 

  • Can I partition a drive in Disk Utility without erasing files?

    Hello,
    According to the third screenshot, I have the option of partitioning an external drive without losing files already on it, but when I try to do so, I only get a message indicating that it will erase the disk:  http://osxdaily.com/2009/11/20/resize-partitions-in-mac-os-x-with-disk-utility/
    I backuped my internal drive with Time Machine and I would now like to partition it so that only one half is for Time Machine purposes.  If it's possible to do that without starting from scratch, if I decide later to eliminate that partition, would that require losing any files?
    Thanks.

    You may find your answer here. Have a look around.
    http://pondini.org/OSX/DU.html

  • How do I transfer the iTunes library from my Mac to Windows without moving files?

    I have my Media on a Windows file share and currenty my Mac's iTunes library is pointed there. I just installed iTunes on my Windows box and now I want to transfer the iTunes database( music, playcounts, playlist, etc ) to the Windows iTunes while keeping the files in place as they don't need to be moved.
    Both systems are authorized on my acount and have home sharing turned on. They are both pointed to the same Media folder in their library settings.
    How can I make the transfer without uncessary file copying?

    The key file is the library.itl file.  This is the file iTunes uses to store all the information it presents to you when you open the program.  Well, there's also a few other library files as well as the artwork folder, but the .itl file is the center of it.  You don't say whether or not the PC has its own library with unique content, or if you are trying to duplicate the library for both.  If the PC library is empty try copying the whole iTunes folder (which contains no media according to you) to the PC, then start iTunes with the shift key held down and guide iTunes to the new library file set (or copy it over the one currently on your PC and just start normally).
    What are the iTunes library files? - http://support.apple.com/kb/HT1660
    More on iTunes library files and what they do - http://en.wikipedia.org/wiki/ITunes#Media_management
    What are all those iTunes files? - http://www.macworld.com/article/139974/2009/04/itunes_files.html
    Where are my iTunes files located? - http://support.apple.com/kb/ht1391
    iTunes: How to move [or copy] your music [library] to a new computer [or another drive] - http://support.apple.com/kb/HT4527 - a somewhat bewildering and not always easily understandable set of options.
    Windows users see tip at: https://discussions.apple.com/message/18879381

  • Upload file without using file upload UI Element

    Hi all.
    I need upload a .txt file without using file upload UI Element because filename is not insert by user. The filename is generated by program. I try to use 'GUI_UPLOAD' and 'WS_UPLOAD' but don't work.
    Many thanks in advance.

    As you correctly pointed out we cannot use the gui_upload and gui_download fm's in webdynpro because they require sap gui and WD Components generally run in a HTML or Portal environment.
    The only option available is File Upload Element

  • How can I get a filename without the file extension?

    I using a JFileChooser to select and read a file. Now I want to get the filename without the file extension
    JFileChooser j = new JFileChooser;
    String file = j.getSelectedFile.getName();
    At the moment I get this result "file.dat". I need only the filename.....
    Thank you
    Thomas

    It's quite that.
    Here is the code to do that (and the method to get only the extension):
         public String getFileName(String text) {
              int ind = text.lastIndexOf(".");
              if(0<ind && ind<(text.length()-1)) {
                   return text.substring(0, ind);
              return(null);
         public String getFileExtension(String text) {
              int ind = text.lastIndexOf(".");
              if(0<ind && ind<(text.length()-1)) {
                   return text.substring(ind+1).toLowerCase();
              return(null);
         }(I used 0<ind instead of ind>0 because with the code formatting there is a bug with > )
    I hope this helps,
    Denis

  • SQL - How to attach FileStream enabled db without log file

    I'm trying to attach a FileStream enabled database without a log file. My SQL looks something like this:
    USE master
    CREATE DATABASE MyDB
    ON PRIMARY(NAME = N'MyDB', FILENAME = 'C:\myDB.MDF' ),
    FILEGROUP myFileGroup CONTAINS FILESTREAM ( NAME = myData, FILENAME = 'C:\myFileGroup')      
    For Attach
    Here is the error I'm receiving:
    Msg 5173, Level 16, State 3, Line 2
    One or more files do not match the primary file of the database.
    If you are attempting to attach a database, retry the operation with the correct files.  
    If this is an existing database, the file may be corrupted and should be restored from a backup.
    Does anyone know if it's possible to attach a FileStream enabled database without the original log file?  Thanks!

    Hi cgregory,
    The error might occur if the database is not shutdown cleanly. In this case, log file is required, or, you will have some data lost. Please pay attention to this thread addressing this type of issue:
    attaching DB without .ldf file ???
    For attach a database with FILESTREAM enabled, please refer to this article:
    How to Detach and Attach a SQL Server FILESTREAM Enabled Database.
    Stephanie Lv
    TechNet Community Support

  • Sending mail without attachment file

    Hi Sapfans:
    I would like to send mail without attachment file, just a notice,
    needing multiple receiver, can change the mail title,
    Which function shoud I use?
    I just found out sending mail with attachment file there,
    Thanks a lot!

    Hi Alchie,
    Please take a look at my example below. It sens e-mail to multiple recipients without attachments.
    FUNCTION-POOL zts0001                    MESSAGE-ID sv.
    INCLUDE lsvimdat                                . "general data decl.
    INCLUDE lzts0001t00                             . "view rel. data dcl.
    */ Author: Aris Hidalgo
    */ Created on: September 7, 2006
    */ Purpose of program: This will send out e-mails to specified users in
    */ custom table ZSHIPTO_EMAIL whenever records have been deleted or
    */ modified via the maintenance view of ZTS0001. The changes will also
    */ be reflected in custom table ZTS_STPGEOLOC.
    TABLES: zts_stpgeoloc,
            zshipto_email,
            kna1.
    FIELD-SYMBOLS: <fs_old_total> TYPE ANY.
    *       CLASS lcl_main DEFINITION ABSTRACT
    CLASS lcl_main DEFINITION ABSTRACT.
      PUBLIC SECTION.
        TYPES: BEGIN OF t_zts0001_old,
                kunnr    TYPE zts0001-kunnr,
                cdseq    TYPE zts0001-cdseq,
                zaddress TYPE zts0001-zaddress,
                zcperson TYPE zts0001-zcperson,
                zcnumber TYPE zts0001-zcnumber,
               END OF t_zts0001_old.
        TYPES: BEGIN OF t_zts0001_new,
                kunnr    TYPE zts0001-kunnr,
                cdseq    TYPE zts0001-cdseq,
                zaddress TYPE zts0001-zaddress,
                zcperson TYPE zts0001-zcperson,
                zcnumber TYPE zts0001-zcnumber,
               END OF t_zts0001_new.
        TYPES: BEGIN OF t_zts_stpgeoloc,
                kunnr    TYPE zts_stpgeoloc-kunnr,
                cdseq    TYPE zts_stpgeoloc-cdseq,
                zaddress TYPE zts_stpgeoloc-zaddress,
                zcperson TYPE zts_stpgeoloc-zcperson,
                zcnumber TYPE zts_stpgeoloc-zcnumber,
               END OF t_zts_stpgeoloc.
        TYPES: BEGIN OF t_del_entries,
                kunnr    TYPE zts0001-kunnr,
                cdseq    TYPE zts0001-cdseq,
                zaddress TYPE zts0001-zaddress,
                zcperson TYPE zts0001-zcperson,
                zcnumber TYPE zts0001-zcnumber,
                name1    TYPE kna1-name1,
               END OF t_del_entries.
        TYPES: BEGIN OF t_modified_entries,
                kunnr       TYPE zts0001-kunnr,
                cdseq       TYPE zts0001-cdseq,
                old_address TYPE zts0001-zaddress,
                new_address TYPE zts0001-zaddress,
                old_person  TYPE zts0001-zcperson,
                new_person  TYPE zts0001-zcperson,
                old_number  TYPE zts0001-zcnumber,
                new_number  TYPE zts0001-zcnumber,
                name1       TYPE kna1-name1,
               END OF t_modified_entries.
        DATA: gt_zts0001_old      TYPE STANDARD TABLE OF t_zts0001_old,
              gt_zts0001_new      TYPE HASHED   TABLE OF t_zts0001_new
                                           WITH UNIQUE KEY kunnr cdseq,
              gt_zts_stpgeoloc    TYPE STANDARD TABLE OF t_zts_stpgeoloc,
              gt_del_entries      TYPE STANDARD TABLE OF t_del_entries,
              gt_modified_entries TYPE STANDARD TABLE OF t_modified_entries,
              gt_zshipto_email    TYPE STANDARD TABLE OF zshipto_email,
              t_maildata          TYPE sodocchgi1,
              gt_mailtxt          TYPE STANDARD TABLE OF solisti1,
              gt_mailrec          TYPE STANDARD TABLE OF somlreci1.
        DATA: v_old_total     TYPE i,
              v_new_total     TYPE i,
              v_flag(1)       TYPE c,
              v_counter(1)    TYPE c,
              v_contents(255) TYPE c.
    ENDCLASS.
    *       CLASS lcl_get_old_recs DEFINITION
    CLASS lcl_get_old_recs DEFINITION INHERITING FROM lcl_main.
      PUBLIC SECTION.
        METHODS: export_old_recs.
    ENDCLASS.
    *       CLASS lcl_get_old_recs IMPLEMENTATION
    CLASS lcl_get_old_recs IMPLEMENTATION.
      METHOD export_old_recs.
        SELECT kunnr cdseq zaddress zcperson zcnumber
        FROM zts0001
        INTO TABLE gt_zts0001_old.
        v_old_total = sy-dbcnt.
        ASSIGN v_old_total TO <fs_old_total>.
        EXPORT gt_zts0001_old = gt_zts0001_old TO MEMORY ID 'AVH'.
        CLEAR gt_zts0001_old. REFRESH gt_zts0001_old.
      ENDMETHOD.
    ENDCLASS.
    *       CLASS lcl_old_and_new DEFINITION
    CLASS lcl_old_and_new DEFINITION INHERITING FROM lcl_main.
      PUBLIC SECTION.
        METHODS: compare_old_and_new.
    ENDCLASS.
    *       CLASS lcl_old_and_new IMPLEMENTATION
    CLASS lcl_old_and_new IMPLEMENTATION.
      METHOD compare_old_and_new.
        DATA: wa_del_entries    LIKE LINE OF gt_del_entries.
        FIELD-SYMBOLS: <fs_old> LIKE LINE OF gt_zts0001_old,
                       <fs_new> LIKE LINE OF gt_zts0001_new.
        SELECT kunnr cdseq zaddress zcperson zcnumber
        FROM zts0001
        INTO TABLE gt_zts0001_new.
        v_new_total = sy-dbcnt.
        IF v_new_total <> <fs_old_total>.
          IMPORT gt_zts0001_old = gt_zts0001_old FROM MEMORY ID 'AVH'.
          LOOP AT gt_zts0001_old ASSIGNING <fs_old>.
            READ TABLE gt_zts0001_new WITH TABLE KEY kunnr = <fs_old>-kunnr
                                                     cdseq = <fs_old>-cdseq
                                                     ASSIGNING <fs_new>.
            IF sy-subrc <> 0.
              MOVE-CORRESPONDING <fs_old> TO wa_del_entries.
              APPEND wa_del_entries TO gt_del_entries.
              CLEAR wa_del_entries.
              DELETE FROM zts_stpgeoloc
              WHERE kunnr = <fs_old>-kunnr
                AND cdseq = <fs_old>-cdseq.
            ENDIF.
          ENDLOOP.
          IF NOT gt_del_entries[] IS INITIAL.
            EXPORT gt_del_entries = gt_del_entries TO MEMORY ID 'DEL'.
          ENDIF.
          REFRESH gt_zts0001_old.
        ENDIF.
      ENDMETHOD.
    ENDCLASS.
    *       CLASS lcl_check_changes DEFINITION
    CLASS lcl_check_changes DEFINITION INHERITING FROM lcl_main.
      PUBLIC SECTION.
        METHODS: check_for_changes.
    ENDCLASS.
    *       CLASS lcl_check_changes IMPLEMENTATION
    CLASS lcl_check_changes IMPLEMENTATION.
      METHOD check_for_changes.
        TYPES: BEGIN OF t_zts_stpgeoloc,
                mandt    TYPE zts_stpgeoloc-mandt,
                kunnr    TYPE zts_stpgeoloc-kunnr,
                cdseq    TYPE zts_stpgeoloc-cdseq,
                zcgeoloc TYPE zts_stpgeoloc-zcgeoloc,
                zaddress TYPE zts_stpgeoloc-zaddress,
                zcperson TYPE zts_stpgeoloc-zcperson,
                zcnumber TYPE zts_stpgeoloc-zcnumber,
               END OF t_zts_stpgeoloc.
        DATA: wa_modified_entries LIKE LINE OF gt_modified_entries,
              lt_zts_stpgeoloc    TYPE HASHED TABLE OF t_zts_stpgeoloc
                                       WITH UNIQUE KEY kunnr cdseq,
              wa_zts_stpgeoloc    LIKE LINE OF lt_zts_stpgeoloc.
        FIELD-SYMBOLS: <fs_zts0001_old> LIKE LINE OF gt_zts0001_old,
                       <fs_zts0001_new> LIKE LINE OF gt_zts0001_new.
        IMPORT gt_zts0001_old = gt_zts0001_old FROM MEMORY ID 'AVH'.
        SELECT kunnr cdseq zcgeoloc zaddress zcperson zcnumber
        FROM zts_stpgeoloc
        INTO CORRESPONDING FIELDS OF TABLE lt_zts_stpgeoloc.
        SELECT kunnr cdseq zaddress zcperson zcnumber
        FROM zts0001
        INTO TABLE gt_zts0001_new.
        LOOP AT gt_zts0001_old ASSIGNING <fs_zts0001_old>.
          READ TABLE gt_zts0001_new WITH TABLE KEY
                                         kunnr = <fs_zts0001_old>-kunnr
                                         cdseq = <fs_zts0001_old>-cdseq
                                         ASSIGNING <fs_zts0001_new>.
          IF sy-subrc = 0.
            READ TABLE lt_zts_stpgeoloc WITH TABLE KEY
                                            kunnr = <fs_zts0001_new>-kunnr
                                            cdseq = <fs_zts0001_new>-cdseq
                                            INTO wa_zts_stpgeoloc.
            IF sy-subrc = 0.
              wa_zts_stpgeoloc-mandt    = sy-mandt.
              wa_zts_stpgeoloc-kunnr    = <fs_zts0001_new>-kunnr.
              wa_zts_stpgeoloc-cdseq    = <fs_zts0001_new>-cdseq.
              wa_zts_stpgeoloc-zcgeoloc = space.
              wa_zts_stpgeoloc-zaddress = <fs_zts0001_new>-zaddress.
              wa_zts_stpgeoloc-zcperson = <fs_zts0001_new>-zcperson.
              wa_zts_stpgeoloc-zcnumber = <fs_zts0001_new>-zcnumber.
              MODIFY zts_stpgeoloc FROM wa_zts_stpgeoloc.
              COMMIT WORK AND WAIT.
            ENDIF.
    *       address
            IF <fs_zts0001_old>-zaddress <> <fs_zts0001_new>-zaddress.
              MOVE: <fs_zts0001_new>-kunnr  TO wa_modified_entries-kunnr,
                    <fs_zts0001_new>-cdseq  TO wa_modified_entries-cdseq,
              <fs_zts0001_old>-zaddress TO wa_modified_entries-old_address,
              <fs_zts0001_new>-zaddress TO wa_modified_entries-new_address.
              v_flag = 1.
            ENDIF.
    *       person
            IF <fs_zts0001_old>-zcperson <> <fs_zts0001_new>-zcperson.
              MOVE: <fs_zts0001_new>-kunnr  TO wa_modified_entries-kunnr,
                    <fs_zts0001_new>-cdseq  TO wa_modified_entries-cdseq,
              <fs_zts0001_old>-zcperson TO wa_modified_entries-old_person,
              <fs_zts0001_new>-zcperson TO wa_modified_entries-new_person.
              v_flag = 1.
            ENDIF.
    *       number
            IF <fs_zts0001_old>-zcnumber <> <fs_zts0001_new>-zcnumber.
              MOVE: <fs_zts0001_new>-kunnr  TO wa_modified_entries-kunnr,
                    <fs_zts0001_new>-cdseq  TO wa_modified_entries-cdseq,
              <fs_zts0001_old>-zcnumber TO wa_modified_entries-old_number,
              <fs_zts0001_new>-zcnumber TO wa_modified_entries-new_number.
              v_flag = 1.
            ENDIF.
          ENDIF.
          IF v_flag = 1.
            APPEND wa_modified_entries TO gt_modified_entries.
            CLEAR wa_modified_entries.
          ENDIF.
    *     update ZTS_STPGEOLOC based from the modified records in ZTS0001
          IF v_flag = 1.
            CLEAR v_flag.
            UPDATE zts_stpgeoloc SET zaddress  = <fs_zts0001_new>-zaddress
                                      zcperson = <fs_zts0001_new>-zcperson
                                      zcnumber = <fs_zts0001_new>-zcnumber
                                   WHERE kunnr = <fs_zts0001_new>-kunnr
                                     AND cdseq = <fs_zts0001_new>-cdseq.
          ENDIF.
        ENDLOOP.
        IF NOT gt_modified_entries[] IS INITIAL.
        EXPORT gt_modified_entries = gt_modified_entries TO MEMORY ID 'MOD'
        ENDIF.
      ENDMETHOD.
    ENDCLASS.
    *       CLASS lcl_messages DEFINITION
    CLASS lcl_messages DEFINITION INHERITING FROM lcl_main.
      PUBLIC SECTION.
        METHODS: create_message.
    ENDCLASS.
    *       CLASS lcl_messages IMPLEMENTATION
    CLASS lcl_messages IMPLEMENTATION.
      METHOD create_message.
        FIELD-SYMBOLS: <fs_email> LIKE LINE OF gt_zshipto_email,
                       <fs_del>   LIKE LINE OF gt_del_entries,
                       <fs_mod>   LIKE LINE OF gt_modified_entries.
        DATA: wa_mailtxt LIKE LINE OF gt_mailtxt,
              wa_mailrec LIKE LINE OF gt_mailrec.
        IMPORT gt_modified_entries = gt_modified_entries
                                     FROM MEMORY ID 'MOD'.
        IMPORT gt_del_entries = gt_del_entries FROM MEMORY ID 'DEL'.
        SELECT * FROM zshipto_email INTO TABLE gt_zshipto_email
         WHERE zevent = '2'.
        IF sy-dbcnt > 0.
    */    routine for records that were deleted
          IF NOT gt_del_entries[] IS INITIAL.
            t_maildata-obj_name  = 'Record Deleted in table ZTS0001'.
            t_maildata-obj_descr = 'Record Deleted in table ZTS0001'.
            t_maildata-obj_langu = sy-langu.
            CLEAR: v_flag, v_counter.
            LOOP AT gt_zshipto_email ASSIGNING <fs_email>.
              LOOP AT gt_del_entries ASSIGNING <fs_del>.
    *           get name of dealer
                SELECT SINGLE name1 FROM kna1
                INTO <fs_del>-name1
                WHERE kunnr = <fs_del>-kunnr.
                IF v_counter IS INITIAL.
                 CONCATENATE: 'FYI: The ff record/s were deleted in tables'
                               'ZTS0001 and ZTS_STPGEOLOC by user' sy-uname
                                                          INTO v_contents
                                                         SEPARATED BY space.
                  wa_mailtxt-line =  v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                ENDIF.
                APPEND wa_mailtxt TO gt_mailtxt. "Extra space for message
                CONCATENATE: 'Dealer :' <fs_del>-kunnr '-'
                             <fs_del>-name1
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                CONCATENATE: 'Ship-To:' <fs_del>-cdseq
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                CONCATENATE: 'Address:' <fs_del>-zaddress
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                CONCATENATE: 'Contact person:' <fs_del>-zcperson
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                CONCATENATE: 'Contact number:' <fs_del>-zcnumber
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                v_counter = 1.
              ENDLOOP.
              wa_mailrec-receiver = <fs_email>-zemail.
              wa_mailrec-rec_type  = 'U'.
              APPEND wa_mailrec TO gt_mailrec.
              CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
                   EXPORTING
                        document_data              = t_maildata
                        document_type              = 'RAW'
                        put_in_outbox              = 'X'
    *                  commit_work                = 'X'
                   TABLES
    *                  object_header              = mailtxt
                        object_content             = gt_mailtxt
                        receivers                  = gt_mailrec
                   EXCEPTIONS
                        too_many_receivers         = 1
                        document_not_sent          = 2
                        document_type_not_exist    = 3
                        operation_no_authorization = 4
                        parameter_error            = 5
                        x_error                    = 6
                        enqueue_error              = 7
                        OTHERS                     = 8.
              IF sy-subrc <> 0.
                MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
              ENDIF.
              CLEAR:    wa_mailtxt, wa_mailrec.
              REFRESH:  gt_mailtxt, gt_mailrec.
            ENDLOOP.
          ENDIF.
          CLEAR wa_mailtxt.
          REFRESH gt_mailtxt.
    */    routine for records that were modified
          IF NOT gt_modified_entries[] IS INITIAL.
            CLEAR t_maildata.
            t_maildata-obj_name  = 'Record changed in table ZTS0001'.
            t_maildata-obj_descr = 'Record changed in table ZTS0001'.
            t_maildata-obj_langu = sy-langu.
            CLEAR v_counter.
            LOOP AT gt_zshipto_email ASSIGNING <fs_email>.
              CONCATENATE: 'FYI: The ff records were changed in tables'
                           'ZTS0001 and ZTS_STPGEOLOC by user' sy-uname
                           INTO v_contents
                           SEPARATED BY space.
              wa_mailtxt-line =  v_contents.
              APPEND wa_mailtxt TO gt_mailtxt.
              CLEAR: wa_mailtxt, v_contents.
              LOOP AT gt_modified_entries ASSIGNING <fs_mod>.
    *          get name of dealer
                SELECT SINGLE name1 FROM kna1
                INTO <fs_mod>-name1
                WHERE kunnr = <fs_mod>-kunnr.
                APPEND wa_mailtxt TO gt_mailtxt.
                CONCATENATE: 'Dealer :' <fs_mod>-kunnr '-'
                             <fs_mod>-name1
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
                CONCATENATE: 'Ship-To:' <fs_mod>-cdseq
                             INTO v_contents
                             SEPARATED BY space.
                wa_mailtxt-line = v_contents.
                APPEND wa_mailtxt TO gt_mailtxt.
                CLEAR: wa_mailtxt, v_contents.
    *           address
                IF NOT <fs_mod>-old_address IS INITIAL AND
                   NOT <fs_mod>-new_address IS INITIAL.
                  CONCATENATE: 'Address from:' <fs_mod>-old_address
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                  CONCATENATE: 'Address to  :' <fs_mod>-new_address
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                ENDIF.
    *           person
                IF NOT <fs_mod>-old_person IS INITIAL AND
                       NOT <fs_mod>-new_person IS INITIAL.
                  CONCATENATE: 'Contact person from:'
                               <fs_mod>-old_person
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                  CONCATENATE: 'Contact person to  :'
                               <fs_mod>-new_person
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                ENDIF.
    *           number
                IF NOT <fs_mod>-old_number IS INITIAL AND
                       NOT <fs_mod>-new_number IS INITIAL.
                  CONCATENATE: 'Contact number from:'
                               <fs_mod>-old_number
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                  CONCATENATE: 'Contact number to  :'
                               <fs_mod>-new_number
                               INTO v_contents
                               SEPARATED BY space.
                  wa_mailtxt-line = v_contents.
                  APPEND wa_mailtxt TO gt_mailtxt.
                  CLEAR: wa_mailtxt, v_contents.
                ENDIF.
              ENDLOOP.
              wa_mailrec-receiver = <fs_email>-zemail.
              wa_mailrec-rec_type  = 'U'.
              APPEND wa_mailrec TO gt_mailrec.
              CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
                   EXPORTING
                        document_data              = t_maildata
                        document_type              = 'RAW'
                        put_in_outbox              = 'X'
    *                  commit_work                = 'X'
                   TABLES
    *                  object_header              = mailtxt
                        object_content             = gt_mailtxt
                        receivers                  = gt_mailrec
                   EXCEPTIONS
                        too_many_receivers         = 1
                        document_not_sent          = 2
                        document_type_not_exist    = 3
                        operation_no_authorization = 4
                        parameter_error            = 5
                        x_error                    = 6
                        enqueue_error              = 7
                        OTHERS                     = 8.
              IF sy-subrc <> 0.
                MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
              ENDIF.
              CLEAR:    wa_mailtxt, wa_mailrec.
              REFRESH:  gt_mailtxt, gt_mailrec.
            ENDLOOP.
          ENDIF.
        ENDIF.
        FREE MEMORY ID 'AVH'.
        FREE MEMORY ID 'DEL'.
        FREE MEMORY ID 'MOD'.
      ENDMETHOD.
    ENDCLASS.
    START-OF-SELECTION.
    *       FORM get_orig_contents_of_zts0001                             *
    */ before saving the data in the database
    FORM get_orig_contents_of_zts0001.
      DATA: get_old_recs TYPE REF TO lcl_get_old_recs.
      CREATE OBJECT get_old_recs.
      CALL METHOD get_old_recs->export_old_recs.
    ENDFORM.
    *       FORM get_rev_contents_of_zts0001                              *
    */ after saving the data in the database
    FORM get_rev_contents_of_zts0001.
      DATA: old_and_new   TYPE REF TO lcl_old_and_new,
            check_changes TYPE REF TO lcl_check_changes,
            messages      TYPE REF TO lcl_messages.
      CREATE OBJECT: old_and_new, check_changes, messages.
      CALL METHOD old_and_new->compare_old_and_new.
      CALL METHOD check_changes->check_for_changes.
      CALL METHOD messages->create_message.
    ENDFORM.
    *       FORM move_latest_date_and_user                                *
    FORM move_latest_date_and_user.
      zts0001-zcreated_by   = sy-uname.
      zts0001-zchanged_date = sy-datum.
    ENDFORM.
    Hope it helps...
    P.S. Please award points if it helps...

  • Would like to change name of administrator without losing files etc.  How do I do it?

    Would like to change name of administrator without losing files etc.  How do I do it without damge?

    Changing username or short name- User Account

Maybe you are looking for