Replace Filename text by start/end position?

I could do this in php, but I know nothing of applescript. The main function I need is PHP's substr_replace, to rename files in a passed array, by start/end string positions, with passed text.
Basically I'm looking for an applescript function to add to an Automator workflow, that will replace filenames with text, by character position. The applescript function would have 4 parameters, (files:Array, startPosition:int, endPosition:int, replaceWith:String). The first is an array of the files passed by Automator's "Get Selected Files" func, then the starting and ending positions for what is to be replaced, finally followed by the string to replace with.
So something like,
function renameFilenamesByPosition(files, startPos, endPos, replaceWith)
for(i=0;i<count(files);i++)
file = files;
oldName = basename(file);
newName = substr_replace(oldName, replaceWith, startPos, endPos);
rename(oldFilename, newName);
Any help in coming up with an applescript that I can do this, and be inserted into an Automator workflow, is MUCH APPRECIATED!! I often have files with number tags, that I'd like to have removed.

I had a substring handler that converted fairly readily, but I was looking for something more general-purpose to put into an Automator action. Using an action is good for making the interface not quite so ugly, but there is a bit more to do to make sure it is robust enough to take whatever the other actions can throw at it. I finally decided on an action that trimmed an adjustable number of characters from the beginning or end, with an option to add a text variable - something that the existing rename doesn't do.
As for my replacement handler, the main difference is that it uses the normal AppleScript index ranges, and the index items can also be text strings. There is also a bit more code to take care of stuff like negative or swapped indexes (yours definitely doesn't like that). It does work differently than the PHP function, which is probably not what you were looking for.
<pre style="
font-family: Monaco, 'Courier New', Courier, monospace;
font-size: 10px;
margin: 0px;
padding: 5px;
border: 1px solid #000000;
width: 720px; height: 340px;
color: #000000;
background-color: #FFEE80;
overflow: auto;"
title="this text can be pasted into the Script Editor">
on run -- examples
set TheText to "00012-myfile.jpeg"
ReplaceTheText of TheText between 1 thru 6 by ""
-- ReplaceTheText of TheText between "000" thru "-" by ""
-- ReplaceTheText of TheText between 1 thru "-" by "xxxx"
display dialog "\"" & the result & "\""
end run
to ReplaceTheText of SomeText between StartItem thru EndItem by ReplacingText
replaces the text between the specified items with ReplacingText
item searches are from left to right (beginning to end)
if an item is not found, the replacement is from the beginning or end
parameters - SomeText [text]: the text to modify
StartItem [mixed]: the starting item or index (negative number is from the end)
EndItem [mixed]: the ending item or index (negative number is from the end)
ReplacingText [Text]: the replacement text
returns [text]: the modified text, or the original text if error (index out of range, etc)
set SomeText to SomeText as text
set TextCount to (count SomeText)
if class of StartItem is in {integer, real} then
if StartItem is less than 0 then set StartItem to ((TextCount + 1) + StartItem) -- make positive index
if (StartItem is greater than TextCount) or (StartItem is less than 1) then return SomeText -- out of range
else
set StartItem to offset of (StartItem as text) in SomeText
if result is 0 then set StartItem to 1 -- the beginning
end if
if class of EndItem is in {integer, real} then
if EndItem is less than 0 then set EndItem to ((TextCount + 1) + EndItem) -- make positive index
if (EndItem is greater than TextCount) or (EndItem is less than 1) then return SomeText -- out of range
else
get (offset of (EndItem as text) in (text StartItem thru -1 of SomeText))
if result is 0 then
set EndItem to TextCount -- the end
else
set EndItem to StartItem + result + (count EndItem) - 2
end if
end if
if StartItem is greater than EndItem then set {StartItem, EndItem} to {EndItem, StartItem} -- swap
if StartItem is not 1 then
set StartItem to text 1 thru (StartItem - 1) of SomeText
else
set StartItem to ""
end if
if EndItem is not TextCount then
set EndItem to text (EndItem + 1) thru TextCount of SomeText
else
set EndItem to ""
end if
return StartItem & ReplacingText & EndItem
end ReplaceTheText
</pre>

Similar Messages

  • Why does my cursor not automatically select the entire word when I try to select text by starting/ending in the middle of a word?

    In any other browser I've used (or word processor, for that matter) when I select text using my mouse cursor, if I start and/or end in the middle of a word, it automatically selects the whole word when I'm selecting more than one word. But for some reason this is not happening in Firefox. If I try to select say 3 words, and I start in the middle of the first word and end in the middle of the last word, it will only select those parts, not all 3 words entirely.

    Firefox allows to select part of a word. You can select a word with a double click and use Shift + left click to set the end of the selection, so you need to click at the end of the last word instead of in it.

  • Find start/end of word contained in text.

    I feel really silly asking this, but my brain doesn't seem to want to work at the moment and I can't find my old semester 1 examples.
    While I can easily solve this in C++ trying to do it in Java is a bit of a mystery. size_t = found, str.find() string::npos -> etc
    Basically I'm trying to implement a default highlighter. The words I need to search for AFAIK only appear once each in the Document or not at all.
    SQL queries, SELECT, FROM, WHERE, etc.
    I'm going off an example I found here: [http://www.java2s.com/Code/Java/Swing-JFC/Anexampleofhighlightingmultiplediscontiguousregionsofatextcomponent.htm]
    Which searches for vowels within a document and highlights. So i figured it would be an easy switch to get it to do what I wanted, but I've been plugging away at it for a few hours now and can't solve it.
    Would be a lot easier if String.contains(CharSequence cs) gave something back more useful than a boolean... integer would be nice :(
    Anyway sample is below, to make it simple I have a simple query in the text pane, and only search for the 3 words, select from where.
    Can anyone tell me how I would go about telling the addHighlight() method of the word found?
    import java.awt.BorderLayout;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.text.*;
    public class MultiHighlight implements ActionListener
         private JTextComponent comp;
         private String[] wordsToHighlight;
         public MultiHighlight(JTextComponent c, String[] words)
              comp = c;
              wordsToHighlight = words;
         public void actionPerformed(ActionEvent e)
              // highlight
              Highlighter h = comp.getHighlighter();
              h.removeAllHighlights();
              String text = comp.getText().toUpperCase();
              for (int i=0;i<wordsToHighlight.length;i++)
                   if (text.contains(wordsToHighlight))
                        // find start, find end... ?
                        h.addHighlight(start, end, DefaultHighlighter.DefaultPainter)
         public static void main(String args[])
              JFrame frame = new JFrame("MultiHighlight");
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              JTextArea area = new JTextArea(5, 20);
              area.setText("Select *\nFrom stuff s, more m\nWhere s.otherstuff = m.otherstuff.");
              frame.getContentPane().add(new JScrollPane(area), BorderLayout.CENTER);
              JButton b = new JButton("Highlight All SQL words");
              String[] wordsToLookFor = { "SELECT", "FROM", "WHERE" };
              b.addActionListener(new MultiHighlight(area, wordsToLookFor));
              frame.getContentPane().add(b, BorderLayout.SOUTH);
              frame.pack();
              frame.setVisible(true);

    int start = text.indexOf(wordsToHighlight);
                        int end = start + wordsToHighlight[i].length();
                        try {
                             h.addHighlight(start, end, DefaultHighlighter.DefaultPainter);
                        } catch (BadLocationException e1) {
                             e1.printStackTrace();

  • How to replace a substring that starts with and end with another substring?

    Hi,
    I am trying to parse data from HTML tables. First I want to remove all useless tags like <font>. Now, how can I remove substrings like-
    *<font face="Verdana, Arial, Helvetica, sans-serif" size="1">My_Data_to_parse</font>*
    I was searching for any method which replaces a substring what starts with a substring (in this case "<font") and ends with another substring (in this case ">") . Is there any method like that? Or any better solution?
    Another situation like the following-
    *<td align="left" height="30" width="100%">*
    In this case I want to remove all the height, align , width etc and make it as simple as "<td>". How can I do that?
    Finally, all I am trying to do just to parse data from the tables in a html file. Is there any parser API or library to help me do that? Or to bring the data down to array from the tables based on table structure? Please suggest me.
    Thanks in advance.

    probably the best place to start is to search for the "<keyword" of all of the html keywords, then search for the location of the next ">" - this will indicate the end of the <keyword> opening tag.

  • How can I replace a text/range of text enclosed in a XML tag

    I want to replace a piece of text enclosed inside a XML tag in a text frame.
    In my input parameters, I have the In-design document page number, text frame UID in that page and the XML tag name inside that text frame
    which encloses my old text.
    what command/function/interface can I use which can help me to replace the existing text with the input text ?
    eg:
    [old text]  -----> [new text]
    where [ ] is XML tag with name tag1.

    After some trail and POC, I was able to write the below piece of code.
    This detects the starting and ending position of the marker and based on that we can replace the text inside it. Hope it helps.
    InterfacePtr<IDocumentSignalData> data(signalMgr, UseDefaultIID());
            if (data == nil)
                break;
            UIDRef docRef = data->GetDocument();
            InterfacePtr<IDocument> doc(docRef, IID_IDOCUMENT);
      IDataBase *db = docRef.GetDataBase();
      //Get the spread
      InterfacePtr<ISpreadList> spreadList(doc, UseDefaultIID());
      int32 spreadCount = spreadList->GetSpreadCount();
      for ( int32 spreadIndex = 0; spreadIndex < spreadCount; spreadIndex++ )
      // Get the spread reference
      UIDRef spreadUIDRef(db, spreadList->GetNthSpreadUID(spreadIndex));
      // Get the spread object
      InterfacePtr<ISpread> spread(spreadUIDRef, UseDefaultIID());
      int32 numberOfPages = spread->GetNumPages();
      for (int32 nPage = 0; nPage < numberOfPages; nPage++ )
      UIDList pageItemList(db);
      spread->GetItemsOnPage(nPage, &pageItemList, kFalse, kFalse);
      // Iterate the page items and save off the UIDs of frames.
      int32 pageItemListLength = pageItemList.Length();
      for (int32 j = 0; j < pageItemListLength; j++ )
      UIDRef pageItemRef = pageItemList.GetRef(j);
      InterfacePtr<IFrameType> frame(pageItemRef, UseDefaultIID());
      if( frame->IsTextFrame() )
      //Now trying to get the marker position for XML tag
      TextIndex startPos=0,endPos=0;
      IXMLReferenceData *xmlReferenceData= Utils<IXMLUtils>()->QueryXMLReferenceData(pageItemRef);
      XMLReference ref = xmlReferenceData->GetReference();
      //IIDXMLElement *element = ref.Instantiate();
      InterfacePtr<IIDXMLElement> element(ref.Instantiate());
      UID tagUID = element->GetTagUID();
      WideString elementName = element->GetTagString();
      for(int32 i=0; i < element->GetChildCount(); i++)
      XMLReference childRef = element->GetNthChild(i);
      InterfacePtr<IIDXMLElement> child_element(childRef.Instantiate());
      tagUID = child_element->GetTagUID();
      elementName = child_element->GetTagString();
      int32 index=0;
      Utils<IXMLUtils>()->GetElementMarkerPositions(child_element,&startPos,&endPos);
      startPos += 1; // move forward to exclude the starting tag
      } // iterate pages in spread

  • Replacing some text in a text file using TEXT_IO built-in package

    Hi everybody...
    I have written a form procedure in order to replace some text in a text document using the TEXT_IO built-in package. Although the text to be replaced is found , eventually the text is not replaced....
    Obviously , the new file - after the replacement - is not saved(?)..
    So , what should i do?
    The procedure is as follows...
    BEGIN
    in_file := Text_IO.Fopen(filename, 'a');
    LOOP
    Text_IO.Get_Line(in_file, linebuf);
    IF INSTR(linebuf,'C:\LIBS\')<>0
    THEN
    I:=INSTR(linebuf,'C:\LIBS\')-1;
    SUB_STR_BEFORE_VAR:=SUBSTR(linebuf,1,I);
    SUB_STR_AFTER_VAR:=SUBSTR(linebuf,I+9);
    Text_IO.PUT(in_file,SUB_STR_BEFORE_VAR||'D:/SIM/'||SUB_STR_AFTER_VAR);
    END IF;     
    END LOOP;
    EXCEPTION
    WHEN no_data_found THEN
    Text_IO.Fclose(in_file);
    END;
    WHERE :linebuf : is the variable in which the line contents are saved...
    SUB_STR_BEFORE_VAR : is the variable which keeps the substring before the first character of the search string
    SUB_STR_AFTER_VAR : is the variable which keeps the substring after the last character of the search string
    I : variable which keeps the number of character in line (variable linebuf) in which the first character of the search string is found
    Thanks , a lot
    Simon

    Hello,
    The A (Append) mode is used to add data at the end of the file. It will not replace existing data.
    Open the source file in R mode, open the target file in W mode, then rename it with the source name when finished.
    Francois

  • How Can I replace newScale Text Strings with Custom Values?

    How Can I replace newScale Text Strings with Custom Values?
    How can I replace newScale text strings with custom values?
    All  newScale text is customizable. Follow the procedure below to change the  value of any text string that appears in RequestCenter online pages.
    Procedure
    1. Find out the String ID of the text string you would like to overwrite by turning on the String ID display:
    a) Navigate to the RequestCenter.ear/config directory.
    b) Open the newscale.properties file and add the following name-value pair at the end of the file:res.format=2
    c) Save the file.
    d) Repeat steps b and c for the RmiConfig.prop and RequestCenter.prop files.
    e) Stop and restart the RequestCenter service.
    f) Log  in to RequestCenter and browse to the page that has the text you want  to overwrite. In front of the text you will now see the String ID.
    g) Note down the String ID's you want to change.
    2. Navigate to the directory: /RequestCenter.ear/RequestCenter.war/WEB-INF/classes/com/newscale/bfw.
    3. Create the following sub-directory: res/resources
    4. Create the following empty text files in the directory you just created:
    RequestCenter_0.properties
    RequestCenter_1.properties
    RequestCenter_2.properties
    RequestCenter_3.properties
    RequestCenter_4.properties
    RequestCenter_5.properties
    RequestCenter_6.properties
    RequestCenter_7.properties
    5. Add the custom text strings to the appropriate  RequestCenter_<Number>.properties file in the following manner  (name-value pair) StringID=YourCustomTextString
    Example: The StringID for "Available Work" in ServiceManager is 699.
    If you wanted to change "Available Work" to "General Inbox", you  would add the following line to the RequestCenter_0.properties file
         699=General Inbox
    Strings are divided into the following files, based on their numeric ID:
    Strings are divided into the following files, based on their numeric ID:
    String ID  File Name
    0 to 999 -> RequestCenter_0.properties
    1000 to 1999 -> RequestCenter_1.properties
    2000 to 2999 -> RequestCenter_2.properties
    3000 to 3999 -> RequestCenter_3.properties
    4000 to 4999 -> RequestCenter_4.properties
    5000 to 5999 -> RequestCenter_5.properties
    6000 to 6999 -> RequestCenter_6.properties
    7000 to 7999 -> RequestCenter_7.properties
    6. Turn off the String ID display by removing (or commenting out) the line "res.format=2" from the newscale.properties, RequestCenter.prop and RmiConfig.prop files
    7. Restart RequestCenter.
    Your customized text should be displayed.

    I've recently come across this information and it was very helpful in changing some of the inline text.
    However, one place that seemed out of reach with this method was the three main buttons on an "Order" page.  Specifically the "Add & Review Order" button was confusing some of our users.
    Through the use of JavaScript we were able to modify the label of this button.  We placed JS in the footer.html file that changes the value of the butt

  • Read character 3+4 from filename and move to other position

    Hello,
    I need a javascript to read my filename (I have the one for the full filename) and especially the 3rd and 4th position of the filename.
    The characters on position 3 and 4 must be moved to the position just before the extension.
    Example:
    4PEN12345.pdf (old name) should be 4P12345_EN.pdf
    Now I have the following script to extract all pages in an existing pdf file to separate pages with all the same suffix before the extension
    /* Extract Pages to Folder */
        var re = /.*\/|\.pdf$/ig;
        var filename = this.path.replace(re,"");
            for ( var i = 0;  i < this.numPages; i++ )
            this.extractPages
                nStart: i,
                nEnd: i,
                cPath : filename + "_page_" + (i+1) + "_EN.pdf"
    Can anybody help me to set me on the right direction?

    Now I have the file 4PBG12345-1.pdf (7 pages included in the pdf).
    Your script as I filled in:
    /* Extract Pages to Folder */
        var re = /.*\/|\.pdf$/ig;
        var filePath = this.path.replace(this.documentFileName, "");
        var oldFileName = this.documentFileName;
        var suffix = oldFileName.substring(2,4);
        var newFileName = oldFileName.substring(0,2) + oldFileName.substring(4).replace(".pdf", "_"+suffix+".pdf");
        var newFilePath = filePath + newFileName;
            for ( var i = 0;  i < this.numPages; i++ )
            this.extractPages
                nStart: i,
                nEnd: i,
                cPath : newFilePath
    Result:
    1 file ==> 4P12345-1_BG.pdf (7 pages included in the pdf)
    Of course, because the syntax for extracting and adding automatic pages is not filled in. So, that was my question, how must I nest to add the right:
    Filepath+oldfilenamesubstring(0,2)+oldfilenamesubstring(4)+_page_i++_+suffix+.pdf in the extract section
    So, my example must result in 7 pdf's:
    4P12345-1_page_1_BG.pdf (with content of page 1)
    4P12345-1_page_2_BG.pdf (with content of page 2)
    4P12345-1_page_3_BG.pdf (with content of page 3)
    4P12345-1_page_4_BG.pdf (with content of page 4)
    4P12345-1_page_5_BG.pdf (with content of page 5)
    4P12345-1_page_6_BG.pdf (with content of page 6)
    4P12345-1_page_7_BG.pdf (with content of page 7)

  • Terminal - how to jump type to the start/end of a word or line?

    How do I jump to the start or end of a word or line in Terminal?
    In other OS X apps, Cmd or Opt + left/right arrows move to the start/end of a line or word respectively.

    Try these (note: the first two require the shift key, at least for me):
    ctrl-A beginning of line
    ctrl-E end of line
    (note: the next two require that you have the Terminal preferences, "settings" , "keyboard" opened, and the checkbox for "Use option as meta key" checked)
    opt-f forward word
    opt-b backward word
    ctrl-u clears the line before the cursor position. If you are at the end of the line, clears the entire line.
    ctrl-f forward character
    ctrl-b backward character
    ctrl-d delete character
    ctrl-l clear screen
    pageup page up in buffer
    pagedwn page down in buffer
    More here:
    http://osxdaily.com/2006/12/19/command-line-keyboard-shortcuts-for-mac-os-x/

  • Preserving tape name and media start/end

    I shoot lots of tapes of random footage to get short general-purpose clips for use later. Years ago when I started, I would preview in the capture window via device control, carefully set log in/out points, and let batch capture make all my little clips. Then I learned how hard that is on my camera's heads, so I got Scenalizer Live and used a new workflow - I captured my whole tape, and then sliced, trimmed, and renamed the "keeper" clips. But since most of my clips don't need audio and SCLive doesn't know how to make a video-only AVI, most recently I've gone back to using PPro for the slice and rename operation, putting the captured video on the timeline, slicing and dicing, and then "exporting to movie" the good pieces to make new AVIs, with only video and with the filenames I want. (Yes, I know there are purists out there who would be concerned about generational loss of methods 2 and 3, but in DV-AVI I just can't see how any mere mortal could tell the difference.)
    But just now I discovered that only my first method preserved the information of where the clip originally came from, i.e. the Tape Name, Media Start, and Media End. All the rest lost that information when I trimmed the clips in either SCLive or PPro. Argh!
    These clips are a lost cause, but for the future, is there a better workflow, one that will preserve both the clip information and my tape heads?

    I agree - the metadata doesn't need to be repeated for every frame - just once for the clip.
    If the clip gets chopped up in PPro (or SCLive or whatever program), it doesn't seem like it should be that hard for the software to just do the math - if I have a two-minute NTSC clip that was originally captured from timecode 12:00:00 to 13:59:29, and I chop it into a 30 sec. clip and a 90 second clip (silly simple example), the resulting two clips should still preserve the Tape Name and other info, and the start/end times should be 12:00:00-12:29:29 and 12:30:00-13:59:29. But instead both PPro and SCLive delete the Tape Name, and the start times of the resaved clips are all zero. Naturally if what is on the timeline when I save is a composite of multiple clips it's a different story, but if the only editing has been to simply put the clip on the timeline and adjust the end points and/or cut with the razor tool, it would be nice if the capture data was preserved.

  • [AS] CS3- Find any text with style, then replace that text with a new applied fill color.

    I am trying to find the simplest way in cs3 to find any text with style, then replace that text with a new fill color. I can find text and change text. I can find a style and change it to a new style. I can't seem to find a style and change the applied fill color. I do not want to change the properties of the style, just the applied color. Yes, I want the + sign, for now. I know, why not update the style, I am not allowed to. Any help would be great. Since the search is not available, I need a new response.
    Thanks.

    You can work around the bug by just doing a find, then looping through the<br />results, changing the color one at a time. It'll be a fraction slower, but<br />should do the trick:<br /><br />tell application "Adobe InDesign CS3"<br />    set find text preferences to nothing<br />    set properties of find text preferences to {applied paragraph style:"The<br />name"}<br />    set theFinds to find text document 1<br />    repeat with i from 1 to count of theFinds<br />        set properties of item i of theFinds to {fill color:"Replace color"}<br />    end repeat<br />end tell<br /><br />The bug is fixed in CS4, BTW.<br /><br />-- <br />Shane Stanley <[email protected]><br />AppleScript Pro Florida, April 2009 <a href=http://scriptingmatters.com/aspro>

  • Replace the text numbers string in a txt file using C++.. Help Me..

    Read a Document and replace the text numbers in a txt file using c++..
    For ex: 
    Before Document: 
    hai hello my daily salary is two thousand and five and your salary is five billion. my age is 
    twenty-five. 
    After Document: 
    hai hello my daily salary is # and your salary is #. my age is #. 
    All the text numbers and i put the # symbol.. 
    I am trying this code: 
    #include <iostream>
    #include <fstream>
    #include <string>
    using namespace std;
    ifstream myfile_in ("input.txt");
    ofstream myfile_out ("output.txt");
    string line;
    void find_and_replace( string &source, string find, string replace ) {
    size_t j;
    for ( ; (j = source.find( find )) != string::npos ; ) {
    source.replace( j, find.length(), replace );
    myfile_out << source <<endl;
    cout << source << endl;
    int main () {
    if (myfile_in.is_open())
    int i = 0,j;
    //string strcomma ;
    // string strspace ;
    while (! myfile_in.eof() )
    getline (myfile_in,line);
    string strcomma= "two";
    string strspace = "#";
    find_and_replace( line , strcomma , strspace );
    i++;
    myfile_in.close();
    else cout << "Unable to open file(s) ";
    system("PAUSE");
    return 0;
    Please help me.. Give me the correct code..

    Open the file as a RandomAccessFile. Check its length. Declare a byte array as big as its length and do a single read to get the file into RAM.
    Is this a simple text file (bytes)? No problem. If it's really 16-bit chars, use java.nio to first wrap the byte array as a ByteBuffer and then view the ByteBuffer as a CharBuffer.
    Then you're ready for search/replace. Do it as you would in any other language. Be sure to use System.arraycopy() to shove your bytes right (replace bigger than search) or left (replace smaller than search).
    When done, a single write() to the RandomAccessFile will put it all back. As you search/replace, keep track of size. If the final file is smaller than the original, use a setLength() to the new size to avoid extraneous data at the end.

  • Logging start & end time of map execution

    Hello,
    I want to log start & end time of execution of my map (OWB 11g), so I've created a table for this purpose and I used it in every map that I want to log time, twice; First for logging start time, and second for end time.
    I pass a constant with SYSTIMESTAMP value through my log table and also name of my map. but the problem is, both of my records' time (start & end) are very near to each other (difference is in milliseconds!) however my map takes time for more than 2 minutes! So, I've changed my map Target Load Order to: [log table for start time] + [Main tables of my map] + [log table for end time]. I've set my map Use Target Load Ordering option True, too.
    Why it doesn't work? Is there any better solution for logging every map execution time in a table, or not?
    Please help me ...
    Thanks.

    To do that, I have created a view that lists all processes that are running or finished. The view contains fields:
    process_name
    process_type (plsqlmap, plsqlprocedure, processflow, etc)
    run_status (success, error, etc)
    start_time
    end_time
    elapse_time
    inserted
    updated
    deleted
    merged
    You could insert into your log table using select x from this view after every map, or, how I do it, is to insert into log table after every process flow. That is, after my process flow is complete I then select all of the details for the maps of the process flow and insert those details into my log table.
    Here is the SQL for my view. This is for 10.2.0.3. For
    CREATE OR REPLACE FORCE VIEW BATCH_STATUS_LOG_REP_V
    AS
    (SELECT PROCESS_NAME,
    PROCESS_TYPE_SYMBOL,
    (CASE
    WHEN RUN_STATUS_SYMBOL IN ('COMPLETE_OK', 'COMPLETE') THEN 'SUCCESS'
    WHEN RUN_STATUS_SYMBOL IN ('COMPLETE_FAILURE') THEN 'ERROR'
    WHEN RUN_STATUS_SYMBOL IN ('COMPLETE_OK_WITH_WARNINGS') THEN 'WARNINGS'
    ELSE 'NA'
    END
    ) RUN_STATUS_SYMBOL,
    START_TIME,
    END_TIME,
    ELAPSE_TIME,
    NUMBER_RECORDS_INSERTED,
    NUMBER_RECORDS_UPDATED,
    NUMBER_RECORDS_DELETED,
    NUMBER_RECORDS_MERGED
    FROM OWB_RUN.RAB_RT_EXEC_PROC_RUN_COUNTS
    WHERE TRUNC (START_TIME) >= TRUNC (SYSDATE) - 3)
    ORDER BY START_TIME DESC;

  • Pie chart wedge end position.

    Hi,
         I need one urgent help. I need to get start and end position of the wedge corner's in pie-chart. I need to draw some thing using those points. So i need thier global positions.
    Thanks,
    Sathyamoorthi.

    OK, now I get it. So you would need to place your two PieCharts in a s:Group or mx:Canvas. On top of the pie charts, lay another s:Group on which you will do some drawing on its graphics:Graphics object.
    In your case, you need to use dataToLocal() (will give you pixel coordinates in your chart) then localToGlobal()  (convert to Application coordinates) then globalToLocal() (convert to the Top Group or Canvas coordinates you want to draw in) :
    Using the dataToLocal() method
    The dataToLocal() method converts a set of values to x  and y coordinates on the screen. The values you give the method are in  the "data space" of the chart; this method converts these values to  coordinates. The data space is the collection of all possible combinations of data values that a chart can represent.
    The number and meaning of arguments passed to the dataToLocal() method depend on the chart type. For CartesianChart controls, such as the BarChart and ColumnChart controls, the first value is used to map along the x axis, and the second value is used to map along the y axis.
    For PolarChart controls, such as the PieChart control, the first value maps to the angle around the center of the  chart, and the second value maps to the distance from the center of the  chart along the radius.
    The coordinates returned are based on 0,0  being the upper-left corner of the chart. For a ColumnChart control, for  example, the height of the column is inversely related to the x  coordinate that is returned.
    http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/DisplayOb ject.html#localToGlobal%28%29
    http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/DisplayOb ject.html#globalToLocal%28%29

  • How to remove the START/END marker ?

    Hi. At the top of the arrange page , where the bars and beats are numbered , i have these Start and End markers , which i can move about but cant get rid of. Once the song hits the end point, recording stops. I can move this further away to increase recording time, but i how can i remove it completely?
    Thanks
    Faisal

    Hey there,
    i don't think you can remove the Song End position.
    But you can extended it as you wish for it to stop at the song position you like.
    You can do that by double clicking on the right bottom of the transport window where you can add manually the Song's End position or on the bar ruler just drag it to the bar psn you want it to be .
    if you are running 7.2 you will find that under the tempo in the transport window.

Maybe you are looking for

  • How to solve this ATP problem

    dear all, wen i m creating the sales order i m getting this problem.... following is the error The sum of the requested quantity exceeds the sum of stock items Message no. VV041 Diagnosis The availability check in your system is configured in such a

  • I turned off facetime, if i restart my iphone, will it turn on and send the sms to apple again?

    I turned off facetime, if i restart my iphone, will it turn on and send the sms to apple to active again?

  • Naming method

    Hi, we are taking into consideration the possibility to use directory or nis naming methods. Do these types of naming methos have disadvantages when compared to local naming (TAF support, client load balancing,...)? thanks in advance

  • 6680: screen is broken, how to backu?

    Hello, I have a 6680 which has served me flawlessly for many years. Unfortunately it dropped on the stairs and fell about 20 meters and the screen is broken. The phone itself still works I think. I have installed Nokia PC Suite 7.1.180.46 to recover/

  • Aiming and directional movement trouble in 2d game

    Hi! Im writing my second game now, and am having the same problems as i had on my first game. When firing a bullet from a weapon i cant make it go in the exact direction i want it to go. On my last game (http://home.online.no/~stefjako) i made the bu