Missing file name in the sequence

Hi All,
I have struck with the problem which is finding the missing file name in the file_name column. This column also have sequence.
FAX_NAME RECEIVED SENDER FAX_SIZE
fax000000433.tif 01-JAN-07 redro 10k
fax000000434.tif 01-JAN-07 redro 10k
fax000000435.tif 01-JAN-07 redro 10k
fax000000436.tif 01-JAN-07 redro 10k
fax000000437.tif 01-JAN-07 redro 10k
                              One file name missing
fax000000439.tif 01-JAN-07 redro 10k
fax000000440.tif 02-JAN-07 redro 10k
fax000000441.tif 02-JAN-07 redro 10k
fax000000442.tif 02-JAN-07 redro 10k
fax000000443.tif 02-JAN-07 redro 10k
fax000000444.tif 02-JAN-07 redro 10k
fax000000445.tif 02-JAN-07 redro 10k
fax000000446.tif 02-JAN-07 redro 10k
fax000000447.tif 02-JAN-07 redro 10k
fax000000448.tif 02-JAN-07 redro 10k
fax000000449.tif 02-JAN-07 redro 10k
fax000000450.tif 02-JAN-07 redro 10k
Here i want to retrive the Faxname(fax000000438) which is missing
The output like..
I've Designed one BIRT rptdesign for this this in the bellow formate..
FAX_NAME RECEIVED SENDER FAX_SIZE     Missing_Faxes
I've tried with bellow query but i did't get.
select Fax_Name digits from(select min(digits) MN from (select translate(s, '0' || translate(s, '1234567890', ' '), '0') digits 7 from (select filename s from received_faxes))) connect by level8 minus select distinct digits from (select translate(s, '0' || translate(s, '1234567890', ' '), '0') digits 10 from (select filename s from received_faxes))
Could you pls help me..

This?
SQL> with t1 as
  2  (select 'fax000000433.tif' nam from dual union
  3  select 'fax000000434.tif' from dual union
  4  select 'fax000000435.tif' from dual union
  5  select 'fax000000436.tif' from dual union
  6  select 'fax000000437.tif' from dual union
  7  select 'fax000000439.tif' from dual union
  8  select 'fax000000440.tif' from dual union
  9  select 'fax000000441.tif' from dual),
10  t2 as
11  (select to_number(mid(nam,4,9)) faxno from t1),
12  t3 as
13  (select max(faxno) ma, min(faxno) mi from t2)
14  select (mi+level - 1) faxno from t3 connect by level <= ma - mi + 1
15  minus
16  select faxno from t2
17  ;
     FAXNO
       438
SQL>

Similar Messages

  • File name generation with sequence number

    Hi All,
    My scenario is, File to File.  I need to generate the filenames at the target side like File1.xml, File2.xml..File9999.xml for each file triggered from source system. The interface tiggesrs multiple times in a day.
    For example, for the first time, 5 files triggered, need to generate File1.xml,File2.xml..File5.xml. After some time the interface might trigger with 10 files, then need to generate files as File6.xml,File7.xml....File15.xml . Once the file count reaches 9999 then need to generate the files from  1 (File1.xml)again.
    Could you please suggest me the possible solutions. For this any Lookups required?
    Regards,
    Praveen Kumar

    Hi Praveen,
    Case 1: If a field in source data carries the information regarding the sequence.
                 You can map this value ( Directly .. or using some transformation ) in some temporary field in the target and then use a Variable substitution at the receiver communication channel.
    Case 2. If the source file name carries the sequence information. then you can enable the Adapter specific settings in the Sender communication channel , and then get the information of the source file name using the Container object in the mapping. Then assign the sequence number to a field in the target , use a Variable substitution at the receiver communication channel.
    Case 3 : If Case 1 and Case 2 are not applicable ... then you have to use a  Ztable  to store the sequence number , a function module to fetch the number , and then use a UDF  in which you will implement the  RFC call logic.Then the same process ....      assign the sequence number to a field in the target , use a Variable substitution at the receiver communication channel.
    BR,
    Sushil.

  • Changing file names in the Information Pane

    Why doesn't changing the names of photographs in the Information Pane also change the name of the files in the iPhoto Library folder??
    If I import photos direct from my camera, the photos are stored with generic file names (like DSC_006) in the Original Folder and the Data folder in iPhoto Library folder. Once stored there, I understand that if you move, delete or "rename" any of those files "in the Finder" that iPhoto may not thereafter be able to see them.
    But I don't understand why if you change those file names in the Information Pane from within the iPhoto application, why the actual file names in the Original and Data folder aren't correspondingly changed.
    I would prefer to eliminate the generic file names and presently the only way that I can do that is to simply transfer the photos from the memory cards, change the file names and then import the files into iPhoto.
    This seems like an unnecessary step.
    Am I missing something here?

    If you want the capability of editing the original file names they you'll need to upgrade to a more professional application like iView MediaPro. Aperture doesn't let you change the original file names from within the application.
    If you need to the use file outside iPhoto with the same name as the Title in iPhoto then you can do just as PhillyPhan pointed out, export to the Desktop using the User Title option.
    Do you Twango?
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've written an Automator workflow application (requires Tiger), iPhoto dB File Backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.

  • Dynamic file name of the attachment in sender mail adapter

    Hi
    I have configured a sender mail adapter which receives some attachments.
    Right now the file name of the attachment is hardcoded to "MailAttachment-1" "MailAttachment-2" using the content-description from "AF_Modules/PayloadSwapBean" module.
    I want to set it to dynamic ie. instead of "MailAttachment-1"... i want it with real name of the attach.
    please suggest a solution w/o the need to develop a custom adapter module.
    Thanks!
    Regards,
    Mariano.

    Thanks Prateek,
    Now, i can see that the name of the original file is into the content type named as  text/xml; name"name of the file.xml" when i send the email from outlook.
    If i send it from hotmail, this is not happend.
    Do you know why happend this?
    If i always would have the original name inside the content type, my problem will be solved.
    Edited by: Mariano Vidal on Feb 13, 2009 2:26 PM

  • Reading file names in the unix box

    Hello,
    I did the following to read the files from the local directory.
    String s1 = "c:\samplefiles"
    File dir = new File(s1);
    if(dir.isDirectory())
    String listoffiles [] = dir.list();
    for(int i = 0; i <listoffiles.length ; i++)
    System.out.println(listoffiles);
    else
    System.out.println("Its not a directory");
    How can i read and print the file names in the unix box?
    Thank You.
    Kumar

    Thank You for the reply.
    In my custom page, i am trying to include a search page which includes date parameters based on which the pdf files in the unix box should be displayed in the page as a list. (The pdf file names start with the date).
    Once the user clicks the file names displayed in the page, i need to open the pdf. This part i can handle but to search the file names based on the parameter names and display in the page as the list is a bit confusing.
    Thank You.

  • Changing of the physical file name of the file after archiving

    Hi all,
    We are in process of archiving  and  completed the process successfully and archived to o:\PRODSID\<filename>.
    When refresh   is happening from Prod to Quality   the archived data will come as O:\PRODSID\<filename> and the archived files will not be accessible since quality system  is not able to find the path with O:\PRODSID\<filename>.
    Is there anyway i can change the physical file name  of the archived files to correct path O:\QUALITYSID\<filename>, i need to change only the SID  only    from PRD to QUALITY.
    Thanks,
    Subhash.G

    Hi Subash,
    Do you want change the Physical File name or the Path from PROD to SID.
    Path :- in the transaction called FILE, double click on Logical Path Definition , select the Logical File and double click on "Assignment on Physical Path to Logical Path" and you can change FILENAME also here
    Thanks,
    Sravanthi

  • How to pass the local file name to the workflow in TC OAWD

    Hi everybody!
    I have to pass the local file name of the image as a parameter to a workflow in TC OAWD.
    By debugging I found the FM which starts the workflow -  'ARCHIV_PROCESS_FAXINPUT' . It has two importing parameters : FRONTENDPATH and BASICFILENAME, but they are not used by calling the FM.
    Do you have an idea if there is a DDIC table, which contains the local file name or another way to solve the issue.
    Thank you in advance.

    Hi,
    Not sure of what you want.
    Have a look at v$session view. Machine column is maybe what you're looking for.
    If you want to retrieve the local host executing remote desktop, it's actually not possible natievely, since it's still remote host that is connecting to the database.
    Hope it helps.

  • Selection of Folder/File name using the same Fun.Module

    Please let me know if there is a function module which can fetch folder name/File name  from the directory path when f4 option of selection screen field is selected. Currently I am able to get the file name using FM F4_DXFILENAME_4_DYNP but the requirment is like I have to select either folder name or the file name depending on user selection.
    Note: Please let me know if there is a single Function module which can get folder name or the file name based on the user selection.i.e, if the user want to select a folder he can select or he can select files in the folder for processing

    Hi sridhar
    try this:
    PARAMETER : TXT_FILE(100).
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR TXT_FILE.
    PERFORM GETFILE.
    start-of-selection.
    PERFORM GETDATA.
    FORM GETDATA.
      DATA : FILENAME TYPE STRING.
      FILENAME = TXT_FILE.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          FILENAME                      = FILENAME
         FILETYPE                       =  'ASC'
         HAS_FIELD_SEPARATOR           = 'X'
        HEADER_LENGTH                 = 0
        READ_BY_LINE                  = 'X'
        DAT_MODE                      = ' '
        CODEPAGE                      = ' '
        IGNORE_CERR                   = ABAP_TRUE
        REPLACEMENT                   = '#'
        CHECK_BOM                     = ' '
      IMPORTING
        FILELENGTH                    =
        HEADER                        =
        TABLES
          DATA_TAB                      = IT_UPLOAD
      EXCEPTIONS
        FILE_OPEN_ERROR               = 1
        FILE_READ_ERROR               = 2
        NO_BATCH                      = 3
        GUI_REFUSE_FILETRANSFER       = 4
        INVALID_TYPE                  = 5
        NO_AUTHORITY                  = 6
        UNKNOWN_ERROR                 = 7
        BAD_DATA_FORMAT               = 8
        HEADER_NOT_ALLOWED            = 9
        SEPARATOR_NOT_ALLOWED         = 10
        HEADER_TOO_LONG               = 11
        UNKNOWN_DP_ERROR              = 12
        ACCESS_DENIED                 = 13
        DP_OUT_OF_MEMORY              = 14
        DISK_FULL                     = 15
        DP_TIMEOUT                    = 16
        OTHERS                        = 17
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.
    FORM GETFILE.
      CALL FUNCTION 'WS_FILENAME_GET'
       EXPORTING
        DEF_FILENAME           = ' '
         DEF_PATH               = '.'
        MASK                   = ' '
        MODE                   = ' '
        TITLE                  = ' '
       IMPORTING
         FILENAME               = TXT_FILE
        RC                     =
      EXCEPTIONS
        INV_WINSYS             = 1
        NO_BATCH               = 2
        SELECTION_CANCEL       = 3
        SELECTION_ERROR        = 4
        OTHERS                 = 5
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.
    <b>This is a part of my BDC program its working for me u try n reply if it works for u.</b>
    regards
    vijay

  • Dynamic File Name - Suppress the Substitue varible

    Hi All,
    I am doing the scenarios like File name at the recevier end would be dynamic for that i take an extra field NAME mapped with UDF which return the file name dynamically. It is working fine and doing good. But the problem here is , this field is the first field in my target structure so i am getting an empty line in the target file.
    So My structure as follows:
    <b>MT_BNK01           1..1
      NAME                1..1
      RECORD             0..Unbound
          --Record_data  0..Unbound</b>
    So in the recever side i written as follows
    Recordset Structure:: RECORD
    <b>RECORD.fieldSeparator = 'nl'
    RECORD.endSeparator = 'nl'</b>
    But according to this weblog i can suppress the empty line but it is not working
    /people/sravya.talanki2/blog/2005/08/11/solution-to-the-problem-encountered-using-variable-substitution-with-xi-sp12
    means, NAME is also in the same level of RECORD in the Structure. So How can i pass the structure as ??
    I tried to pass the RecordSet Structure: NAME,RECORD
    and following parameters, it is not working
    <b>NAME.fieldFixedLength =0
    NAME.fieldLengthTooShortHandling = Cut</b>
    Can you please  suggest me what could be the reason. Tell me what information i need to pass the RecordSet Structure and attrubute information also.
    One more thing like, My sender side it is not picking the empty lines. What could be the reason. I given fieldSeparator and endSeparator as 'nl'. So to catch the empty line what i need to do???
    Thanks in Advance,
    Best Regards,
    Vijay

    Hi Vijaya,
    This can be solved. Actually i had the same scenario where i was getting blank line for the header. Suppose Header was carrying the file name after i cut the value i would get a blank line in file.
    So i added in content conversion parameter the following line
    Header.endSeparator - '0'
    then the first line was not blank.
    Try this, i think your issue will be solved
    Regards,
    Ramesh P
    Message was edited by:
            Ramesh Parashivamurthy

  • Programaticly changing the (suggested only) file name in the save prompt when signing a document?

    When you sign a document in Adobe X (or XI), the system says it needs to save the file first.   Is there some way to change the (suggested only) file name to a different value for that save?
    Right now, people open a blank form - lets call it formX.pdf.   They fill it in and sign it.  The suggested file name for the save is FormX.pdf.   I can generate a unique file name which i'd like to put in place of the suggested default...

    AFAIK, you can't do it with code. Your best option might be to use a form field to show a message to the user when they sign the document with that information.

  • Change File Name In The "File Download" Dialog Box For Web Reports

    Hi All ,
    I followed the below note to change the "File Download" name.
    How To Change The File Name In The "File Download" Dialog Box For Web Reports? Doc ID: Note:418366.1
    However its not working. Has anyone tried this and works fine ?
    Basically I wanted to change the name "rwservlet" when a report is run in an
    excel format.
    Rajesh Alex
    Rajesh Alex

    Hello,
    Have you checked if a HTTP header "Content-disposition" is returned ?
    You can use ieHTTPHEaders for IE
    http://www.blunck.se/iehttpheaders/iehttpheaders.html
    and
    Live HTTP Headers for FireFox
    https://addons.mozilla.org/en-US/firefox/addon/3829
    Regards

  • Path and File name of the attachment

    Hello Srm Guys,
    Where should be the Path and File name of the attachment are stored for a shopping card Item.
    Thanks
    Ram

    Hello Ram,
    Execute the function module BBP_PROCDOC_ITEM_GETDETAIL by providing the item guid,object type . Now it will populate the  et_attach importing parameter with the attatchement details.
    In the ET_ATTATCH internal table , the field PHIO_FNAME/PHIO_PATH_FILE provides the physical storage location of the document.
    Hope this info will be helpful.
    Regards,
    Mani

  • Dynamic file name of the attachment in receiver mail adapter

    Hi
    I have configured a receiver mail adapter which receives the payload as an xml attachment.
    Right now the file name of the attachment is hardcoded to "invoice.xml".
    I want to set it to dynamic ie. instead of "invoice.xml"... i want it as "invoice<invoicenumber>.xml".
    Invoice number is present in the payload.
    please suggest a solution w/o the need to develop a custom adapter module.
    Thanks!
    Regards,
    Faria Mithani

    Hi,
    Go through this thread..
    Dynamic  File Name for Receiver File Adapter
    Regards,
    Sarvesh

  • Retrieving the file name in the adapter module in the sender file adapter

    hi,
    i need to retrieve the file name, in the adapter module. This module is placed in the sender file channel.
    After the file adapter has picked up the file from the file directory, the file is placed in the archived directory.Custom adapter mofule is place in the file shanel. i need to retrieve the file name of the file in the adapter module. Is it possible to retrieve the file name?
    Also is it possible to retrieve the archive directory path in module?
    Regards,
    Meenkashi

    Hi Meenakshi,
    I guess you are looking for this
    /people/daniel.graversen/blog/2006/10/05/dynamic-configuration-in-adapter-modules
    Regards
    Suraj

  • Add file name to the element in target message

    Hi all!
    I try to configure scenario:
    Get all files from directory (it will not be the same number of file every time) and mapping this file to the ERP system. I use File adapter to do this. But what Is necessary I need to mapp the file name to the element in target message.
    I mean: When I have got the RFC structure imprted from ERP and there I have got the element "filename". I would like to put the file name of file which I mapping to this element. Next put the all file contents with file name to the ERP table.
    It is possible to do that??
    I found in sap help that I can keep file name in the message header to get the same target file name, but I wont to put file contents (with file name) to the ERP table not to another file.
    THX for all your opinions.

    The DynamicConfiguration fin inbound message:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Inbound Message
      -->
    - <SAP:DynamicConfiguration xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="Directory">/usr/sap/PXD/put/archive</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileEncoding">ISO646-US</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="SourceFileTimestamp">20061212T121622Z</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileType">txt</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileName">200610.TXT</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="SourceFileSize">124</SAP:Record>
      </SAP:DynamicConfiguration>
    and for Response:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Response
      -->
    - <SAP:DynamicConfiguration xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="SourceFileSize">124</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileType">txt</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="SourceFileTimestamp">20061212T121622Z</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileEncoding">ISO646-US</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="FileName">200610.TXT</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/File" name="Directory">/usr/sap/PXD/put/archive</SAP:Record>
      </SAP:DynamicConfiguration>

Maybe you are looking for