Help on Dimension Build

hi all,
I'm trying to build dimension using +'Add as siblings of lowest level+ ' build method.
In +'Field Properties'+ \ +'Dimension Build Properties'+ tab I select the dimension but no +'field type'+.
New members are created twice. One using member name and one using alias. I'd like to have one new member with its own alias.
Here an exapmple
myfile.txt (containig member names and aliases).
mbr1;alias1 <- existing
mbr2;alias2 <- existing
mbr3;alias3 <- New
Dimension after loading:
mbr1 (alias: alias1) <- existing
mbr2 (alias: alias2) <- existing
mbr3 <- New
alias3 <- New
Expected dimension:
mbr1 (alias: alias1) <- existing
mbr2 (alias: alias2) <- existing
mbr3 (alias: alias3) <- New
Thanks in advance for any help.
Agathe

Hi Agathe,
Here comes my suggestion for a solution....
In order to assign an alias you need to use a valid build method, i.e. generation, level or parent-child.
In your case the following would work:
Dimension Build Setting >Build method: Use level references
Field properties >Dimension Build Properties: Column 1 - Select the dimension in question and select Field type: level (leave the default further down, Number 0)
Column 2 - Select the dimension in question and select Field type: alias (leave the default further down, Number 0)
It will look like this in the Data Prep Editor:
LEVEL0,YourDimension ALIAS0,YourDimension
New members are added to the very end of the dimension.
Mr D.

Similar Messages

  • Essbase 11.1.2 dimension build slow

    Hi All,
    I wonder if anyone has had similar problems or ideas of how to solve the problem I have.
    We've recently migrated to Essbase 11.1.2 running on some big SPARC 64 bit servers and everything is going well.
    We have a problem with dimension builds though. They work, just very slowly taking sometimes over a minute to build a dimension with just 10-20 members in it. With 22 dimensions to build it is taking over 20 minutes to build our dimensions - much more time then loading the gigabytes of data after and this is making the overnight process slower.
    The model was migrated from 11.1.1.2 and we converted the outline. The dimension builds on the old server were 4 minutes. The old rules files are still used but as a test I tried creating a new rules file in the same application to load the meta data from a text file instead of an Oracle SQL server but the same problem exists.
    We use deferred restructure on an ASO model but the restructure is fine - just the 'BuildDimFile' session runs for over a minute and then starts again for over a minute for the next dim build. Number of members seems to make no difference be it 10 or so to 60,000.
    Has anyone got any ideas why or seen similar? Or should I really move out of the dark ages and learn Essbase Studio!
    Thanks for your help,
    Dan

    It seems to be related to the number of dimensions.
    I tried creating a basic outline, two dimensions and loaded with a basic rules file. Took 8 seconds in total, no problem.
    I then tried copying in one of the existing rules files that builds a dimension with four members. Still no problem.
    I then went to the existing outline and deleted all but two dimensions and tried rebuilding with the rules file - it is still quick. I then added the dimensions back, by typing them, all as stored with no members underneath and it suddenly jumps to 40 seconds (of which 30 sec for the dimension build time, 10 sec for the restructure) using the same rules file and data. I'd expect the restructure time to go up, but not the build time.
    Possibly unrelated - EAS often produces an error message when loading an outline stating that I have -1536 MB memory free and the outline is 0 MB do I still wish to load?
    Dan

  • Dimension Build - Change Member Names

    Does anybody know if there is a way to revise outline member names through a load rule without affecting (losing) the data associated with those members? I have a .txt file with the current parent names, child names, aliases, properties, formulas, attributes and UDAs for the Products dimension. I would like to revise all of the level 0 member names without having to do so manually in the outline. Any help would be appreciated.

    You can do this a couple of different ways.You can go into the outline itself through app manager, and witht he FILE drop down, update the outline at that point using your load rule.You could also automate this function with an esscomand script preforming and incremental dimension build (INCBUILDDIM).Randy Rehmer, Cincinnati Bell

  • Urgent: dimension build error.

    Hi folks,
    While running dimensin build , i have got the below errors.
    ERROR - 1007083 - Dimension build failed. Error code [1250029].
    ERROR - 1241101 - Unexpected Essbase error 1007083.
    Please let me know what could be the reason to create these errors.
    I really appreciate your help on the same.
    thanks,

    Hi,
    1. Request to let us know the whats in the log file.
    2. Cant be sure about the error , but found a similar error code in other case .
    http://businessintelligence.ittoolbox.com/groups/technical-functional/hyperion-bi-l/hyperion-essbase-error-code-1250029-3109331
    Sandeep Reddy Enti
    HCC
    http://hyperionconsultancy.com/

  • Duplicate member names allowed dimension build

    I have turned on allow duplicate members in a current ASO essbase cube to test how much rework this will require to allow duplicate aliases.  After I switched the property on, I was recieving errors when attempting to associate an attribute to a dimension through a dimension build rule.  I realized that I needed to use qualified member names in the load file.  Here is an example of the file in Parent  Child  AttributeValue format
    [Domestic-PD].[Test_Comm-PD]     [Test_Comm-PD].[0001-PD]      [Test_Attr-MD].[Test1-MD]
    So I want to associate the attribue Test1-MD to product 0001-PD below.
    Domestic-PD
         Test_Comm-PD
              0001-PD
    What ends up happening is something like this
    Domestic-PD
         Test_Comm-PD
              0001-PD( [Test_Attr-MD].[Test1-MD]
              [Test_Comm-PD].[0001-PD]
    It attaches the attribute to the correct product but then adds an additional member.  I don't want it to add the additional member.  Any idea on what is happening?
    Thanks for any help!

    It ended up working in a different format.  I changed the data file to like below.  I also started over, recopying the outline, turning duplicate members on, so it is possible that there was just something off with the outline earlier.
    Test_Comm-PD     0001-PD      [Test_Attr-MD].[Test1-MD]
    It probably will have issues if there is a duplicate member but luckily I only will have duplicate aliases.

  • Dimension build rule file (Sort member)

    I am loading sorted data for one of the dimension. But its is not coming in sorted fashion in outline. New member which i am adding is always coming in The end.Even though that member is in sorted format in the file.
    I am using generation method . I am putting member for only generation 2 and its alias.I tried using ascending option but it is giving me error
    Can any body help me with this

    As Glenn said, the build only builds new members. In order to have FULL control over the order of a resultant dimension's order, you need to blank out the dimension first and then build via the load rule. As Glenn mentioned, you can do "incremental dimension building". You can do this directly in EAS in an interactive manner by using outline/update outline in pull downs. Just do not save the outline until all your changes are done. You can also accomplish incremental builds via Esscmd or via MaxL, but I'll assume for right now you are still testing. The advantages of the incremental changes is that you can do a number of changes before Essbase commits to doing a restructure, which is time consuming, not to mention confusing if you are "deleting" (however temporary) the entire dimension's hierarchy.
    Regarding setting ascending order
    1) in the load rule's Dimension Build Settings prompt
    2) Select Dimension Build Settings tab
    3) highlight the dimension you are changing
    4) select Ascending for sort order
    This should work...I've never had it error out. However, I will say that it sorts the entire dimension...not just the siblings of a new member. Your upper level members will move as well. Because of this, the ascending sort in a load rule is undesirable. Give it a try. If you don't like the results, just don't save the outline.
    Kevin

  • Incremental Dimension Build

    Hi,
    We have a BSO cube in Essbase in which we have a custom dimension "Product" which has around 30K members, depending on the requests from the business users we need to rebuild this hierarchy with the changes that come in the new files and they may contain
    - New member
    - Removed old members
    - Members moved across different parents within the same dimension
    Till now we have been deleting the whole dimension hierarchy manually and update the outline with the new file but due to this whole data needs to be reloaded, what can be the best possible option that we take in the rule file or any other option so that we don't need to delete the existing hierarchy manually and then reload the whole data.
    I want to know if we have something like incremental dimension build which would take care of all the changes and we would be saved from the manual effort that we need to apply.
    Any suggestions would be really helpful.
    --XAT
    Edited by: XAT on Dec 4, 2010 5:20 PM

    Well you could test it to assure yourself and you should, but if the members are retained, then the data associated with it will be saved. One note, if you are moving members in hierarchies, then you will need to re-agg the database after the dim build

  • Problem with dimension build

    I am trying to build dimensions for a bso cube using Maxl in version 11. I have both the rules file and the textfile in the server. But I am getting the following error.
    import database 'CNFIN1'.'CNGL' dimensions from data_file 'G:\Hyperion\products\Essbase\EssbaseServer\bcpfiles\CNFIN1\CNMarket.txt' using rules_file 'G:\Hyperion\products\Essbase\EssbaseServer\app\CNFIN1\CNGL\GLMktD.rul' on error write to 'G:\Hyperion\products\Essbase\EssbaseServer\log\CNFIN1\CNGL\MktD.err';
    OK/INFO - 1053012 - Object [CNGL] is locked by user [US0T4235].
    OK/INFO - 1053012 - Object [93547618] is locked by user [US0T4235].
    ERROR - 1007083 - Dimension build failed. Error code [1090037]. Check the server log file and the dimension build error file for possible additional info..
    OK/INFO - 1053013 - Object [93547618] unlocked by user [US0T4235].
    ERROR - 1241101 - Unexpected Essbase error 1007083.
    OK/INFO - 1053013 - Object [CNGL] unlocked by user [US0T4235].
    Guys can you help me..Thanks in advance

    First, have you tested this build manually through EAS? Confirm that you can run the dim build manually to eliminate the load rule as a variable that is causing the problem.
    Next, below is a new version of the mxl statement that should work. I altered the syntax to use a server rules_file because the load rule is store in the db directory and you do not need to reference the path or file extension. Also, the backslash is a special character in mxl and needs to be preceded by a backslash. Mxl interprets two backslashes as one.
    import database 'CNFIN1'.'CNGL' dimensions from data_file 'G:\\Hyperion\\products\\Essbase\\EssbaseServer\\bcpfiles\\CNFIN1\\CNMarket.txt' using server rules_file 'GLMktD' on error write to 'G:\\Hyperion\\products\\Essbase\\EssbaseServer\\log\\CNFIN1\\CNGL\\MktD.err';
    Good Luck!

  • Cube hang up is happening during Dimension Build process

    We are using the Excel VBA tool for the Dimension build process.The tool will build the members in 3 applications(Atlaunch,ModeLife,Textcube).Most of the times cube hung up is happening at the Text cube. The dimension build process is described below
    Dimension Build Process :-
    The dimension build process is performed by the Calculation and Dimension Build Tool.
    Before executing dimension build logging in to essbase server is required through the tool
    Once logged in the particular region where dimension build is supposed to be carried out is selected from NML, NA, NE and NS.
    Per region there are 3 applications namely <Region>LNCH, <Region>LIFE and <Region>TEXT and per application there is only 1 database namely AtLaunch, ModeLife and TextData respectively. The cube structure per region is given below:
    NML Region:
    NMLLNCH.AtLaunch
    NMLLIFE.ModeLife
    NMLTEXT.TextData
    NA Region:
    NALNCH.AtLaunch
    NALIFE.ModeLife
    NATEXT.TextData
    NE Region:
    NELNCH.AtLaunch
    NELIFE.ModeLife
    NETEXT.TextData
    NS Region:
    NSLNCH.AtLaunch
    NSLIFE.ModeLife
    NSTEXT.TextData
    The Dimension Build Process is carried out in 2 steps:
    1.     Project Master Code Build –
    2.     Grades, Line Options, Project Description and Reference Currency Build –
    Project Master Code Build:-
    In the Project Master Code Build by the Calculation and Dimension Build Tool the following processes are involved
    •     Some members are dynamically created in <Region>LNCH.AtLaunch, <Region>LIFE. ModeLife and <Region>TEXT. TextData cubes.
    •     Some data is loaded in <Region>LNCH.AtLaunch Cube.
    Grades, Line Option, Project Description and Reference Currency Build:-
    Grades – Some members are dynamically created in <Region>LNCH.AtLaunch and <Region>LIFE. ModeLife cubes.
    Line Options - Some members are dynamically created in <Region>LNCH.AtLaunch
    Project Description - Some members are dynamically created in <Region>TEXT.TextData cube. After that some data is loaded in <Region>TEXT.TextData cube.
    Reference Currency – UDA is updated in <Region>LNCH.AtLaunch, <Region>LIFE.ModeLife cube and UDA and Alias is updated in <Region>TEXT.TextData cube.
    Note: Most of the times during Project Description Build we are experiencing cube hang up / no response for NMLTEXT.TextData, NATEXT.TextData, NETEXT.TextData and NSTEXT.TextData cubes.
    Text cube dimension build process flow :-
    1. Introduction
    The Dimension Build process in CDB system is used for adding new project information in the cubes (AtLaunch, ModelLife and TextData). The text files which are needed for performing dimension build are generated from the child packages and stored in the local system of the user (<LocalDrive>:\GCEP4\Input\CDB_DimensionBuild). The Dimension Build process is carried out in 2 stages:
    1.     Project Master Code Build
    2.     Grades, Line Option, Project Description and Reference Currency Build
    Project Master Code Build:-
    In the Project Master Code Build by the Calculation and Dimension Build Tool the following processes are involved
    •     MsPr_DIM rule is used for the text file F0P_<Project>-<Milestone>-<Version>.txt to build Project Master Code in AtLaunch, Model Life and Text Data Cubes.
    •     MsPr_FLG rule is used to Load some data from the text file F0P_<Project>-<Milestone>-<Version>.txt in AtLaunch Cube.
    Grades, Line Option, Project Description and Reference Currency Build:-
    Dimension Build w.r.t. Grades and Line Options are carried out in AtLaunch and Model Life cubes which is not in scope of this document. Dimension Build w.r.t. Project Description and Reference Currency change are carried out in Text Data cube, so only those parts are discussed in this document.
    2. Project Description Build (Detailed process flow)
    The Project Description Build is carried out in the following steps:
    •     First, any Lock on the particular PMV is checked. If not locked next operation is carried out.
    •     Database availability is checked next (whether any other Dimension build is happening that time or not) and accordingly the availability flag is updated in TextData cube.
    •     Next cache is set from high to low to carry out dimension build.
    •     After cache setting, one rule file at a time is taken (as given in the cfgDL sheet) and dimension build is performed by using the Rule file and text file (created in local by input packages) on the intended cube.
    •     For a particular Rule file “GCM_FDIM” which is used to build CCM information in TextData cube, the following steps are followed by the tool itself:
    o     From the TextData cube all the child members under CCM member under Grades dimension are fetched by “GetMbrInfo” function (GetMbrInfo is used around 2000 to 3000 times).
    o     The child members under CCM for that particular PMV combination are deleted (if previously build).
    •     New child members under CCM are build based on the information provided in the text file F1G_<Project>-<Milestone>-<Version>.txt
    •     Once CCM is build rest of the rule files are used to carry the dimension build operation.
    •     The Dimension build process is carried out by building dimensions as well as updating some flags (loading data).
    •     Reference Currency is updated (if required) at last.
    Why this cube hang up is happening?
    Thanks in advance

    53 questions, all still open. Would you mind marking them as closed as without at least the "question is closed" tag, there's no way for future readers to know if your issues have been resolved or not. I know that I personally use this board for answers quite often and it really helps me when I see that a question has been adequately answered. Points assigned to those who helped you is a nice touch.
    Now to your question: did you by any chance change from one Essbase server to another? You didn't state if this build issue happens all the time, or only if you do all three databases, or much of anything in your post as to the actual process of failure, so I'm kind of guessing wildly on this. If true, you might want to look at: http://timtows-hyperion-blog.blogspot.com/2007/12/essbase-api-error-fix-geeky.html
    Regards,
    Cameron Lackpour
    P.S. MMIC, GlennS, and I were just discussing your kind of build-hierarchy-in-Excel approach last week and how infrequently it's seen nowadays. Not a criticism, I personally like these old-school approaches, probably because I've built one or two myself.

  • Dynamic dimension building

    Hi
    In our project we are using Essbase11.1.4 version.We have a 8 Dimensions.For one dimension we are loading new members ( some account numbers ) every month through informatica-Essbase connector ( Dynamic dimension building ) with rules.The new members are adding below the existing members.But for smartview reporting purpose client wants one member ( Accounts Total ) to be retained always at last.Can we do this ?Please help.
    Version - Essbase 11.1.4
    Thanks
    Edited by: Palem on Dec 10, 2012 10:29 PM

    Can some one help please ?

  • ASO Dimension building slow

    Hi all,
    We just switched from BSO cubes to ASO cubes and found that building complete dimensions (parent child) takes much longer than building BSO dimensions.
    We use the same loadrules as we used for the BSO cubes.
    Is this normal?
    Is there any way to speed up the dimension building?
    Your help is much appreciated!
    rgds,
    Rudy

    Thanks very much guys,
    this info will definitely help us come to an optimized approach.
    btw, since rebuilding all dimension in BSO wasn't any problem I'll now also spend some thoughts on rebuilding only those dimensions that have actually changed.
    No reason to rebuild if nothing has changed, right...<@Cameron,
    We went for this approach because we don't want the business users to manually change the outline.
    So we created an dimension maintenance GUI on a sql table that can be maintained by the business users. That way we're able to load all dimension from sql.
    It has its downside when it comes to e.g. member formulas, but as this more of an administrator task, it's no problem, as we're able to set which dimension should be fully rebuild/resorted.
    Now we have one ODI scenario that's able to load to any essbase cube (ASO and BSO), fully parameterized. IT definitely works great!

  • No valid Dimension Build Fields

    Hi, could you guys give me a little help?
    I'm running a load rule that execute a select on a view. The load rule has 4 columns, and the outline also has 4 columns.
    Col1 - Pointer
    Col2 - Pointer
    Col3 - Pointer
    Col4 - Data Field
    I execute the load rule and the same returns the error "No valid Dimension Build Fields" at error file.
    What could be happenning for Essbase return that error?
    Thanks in advanced.

    You mean Field Properties screen?
    If yes, I checked each column for their equal at Data Load Properties tab.
    And marking "Data field" at Data Load Properties tab for the column that have all the variables.
    I don't know if it make any difference, I copied this load rule from another application. Both applications have the same outline. The only difference is that the select commands are in other tables.
    App1
    Rul1 -> select on table1
    App2
    Rul(the one I'm having problem) -> select on table2
    Another detail, I'm running the load rule with "Update outline" at "Outline" menu in the "File bar".
    Edited by: Rodpg on Dec 1, 2008 2:16 PM
    Edited by: Rodpg on Dec 1, 2008 2:32 PM

  • Can anybody help me to build an interface that can work with this code

    please help me to build an interface that can work with this code
    import java.util.Map;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.io.BufferedReader;
    import java.io.FileReader;
    public class Translate
    public static void main(String [] args) throws IOException
    if (args.length != 2)
    System.err.println("usage: Translate wordmapfile textfile");
    System.exit(1);
    try
    HashMap words = ReadHashMapFromFile(args[0]);
    System.out.println(ProcessFile(words, args[1]));
    catch (Exception e)
    e.printStackTrace();
    // static helper methods
    * Reads a file into a HashMap. The file should contain lines of the format
    * "key\tvalue\n"
    * @returns a hashmap of the given file
    @SuppressWarnings("unchecked")
    private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    HashMap map = null;
    try
    in = new BufferedReader(new FileReader(filename));
    String line;
    map = new HashMap();
    while ((line = in.readLine()) != null)
    String[] fields = line.split("
    t", 2);
    if (fields.length != 2) continue; //just ignore "invalid" lines
    map.put(fields[0], fields[1]);
    finally
    if(in!=null) in.close(); //may throw IOException
    return(map); //returning a reference to local variable is safe in java (unlike C/C++)
    * Process the given file
    * @returns String contains the whole file.
    private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    StringBuffer out = null;
    try
    in = new BufferedReader(new FileReader(filename));
    out = new StringBuffer();
    String line = null;
    while( (line=in.readLine()) != null )
    out.append(SearchAndReplaceWordsInText(words, line)+"\n");
    finally
    if(in!=null) in.close(); //may throw IOException
    return out.toString();
    * Replaces all occurrences in text of each key in words with it's value.
    * @returns String
    private static String SearchAndReplaceWordsInText(Map words, String text)
    Iterator it = words.keySet().iterator();
    while( it.hasNext() )
    String key = (String)it.next();
    text = text.replaceAll("\\b"key"
    b", (String)words.get(key));
    return text;
    * @returns: s with the first letter capitalized
    String capitalize(String s)
    return s.substring(0,0).toUpperCase() + s.substring(1);
    }... here's the head of my pirate_words_map.txt
    hello               ahoy
    hi                    yo-ho-ho
    pardon me       avast
    excuse me       arrr
    yes                 aye
    my                 me
    friend             me bucko
    sir                  matey
    madam           proud beauty
    miss comely    wench
    where             whar
    is                    be
    are                  be
    am                  be
    the                  th'
    you                 ye
    your                yer
    tell                be tellin'

    please help me i don t know how to go about this.my teacher ask me to build an interface that work with the code .
    Here is the interface i just build
    import java.util.Map;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.io.BufferedReader;
    import java.io.FileReader;
    import java.awt.*;
    import javax.swing.*;
    public class boy extends JFrame
    JTextArea englishtxt;
    JLabel head,privatetxtwords;
    JButton translateengtoprivatewords;
    Container c1;
    public boy()
            super("HAKIMADE");
            setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            setBackground(Color.white);
            setLocationRelativeTo(null);
            c1 = getContentPane();
             head = new JLabel(" English to private talk Translator");
             englishtxt = new JTextArea("Type your text here", 10,50);
             translateengtoprivatewords = new JButton("Translate");
             privatetxtwords = new JLabel();
            JPanel headlabel = new JPanel();
            headlabel.setLayout(new FlowLayout(FlowLayout.CENTER));
            headlabel.add(head);
            JPanel englishtxtpanel = new JPanel();
            englishtxtpanel.setLayout(new FlowLayout(FlowLayout.CENTER,10,40));
            englishtxtpanel.add(englishtxt);
             JPanel panel1 = new JPanel();
             panel1.setLayout(new BorderLayout());
             panel1.add(headlabel,BorderLayout.NORTH);
             panel1.add(englishtxtpanel,BorderLayout.CENTER);
            JPanel translateengtoprivatewordspanel = new JPanel();
            translateengtoprivatewordspanel.setLayout(new FlowLayout(FlowLayout.CENTER,10,40));
            translateengtoprivatewordspanel.add(translateengtoprivatewords);
             JPanel panel2 = new JPanel();
             panel2.setLayout(new BorderLayout());
             panel2.add(translateengtoprivatewordspanel,BorderLayout.NORTH);
             panel2.add(privatetxtwords,BorderLayout.CENTER);
             JPanel mainpanel = new JPanel();
             mainpanel.setLayout(new BorderLayout());
             mainpanel.add(panel1,BorderLayout.NORTH);
             mainpanel.add(panel2,BorderLayout.CENTER);
             c1.add(panel1, BorderLayout.NORTH);
             c1.add(panel2);
    public static void main(final String args[])
            boy  mp = new boy();
             mp.setVisible(true);
    }..............here is the code,please make this interface work with the code
    public class Translate
    public static void main(String [] args) throws IOException
    if (args.length != 2)
    System.err.println("usage: Translate wordmapfile textfile");
    System.exit(1);
    try
    HashMap words = ReadHashMapFromFile(args[0]);
    System.out.println(ProcessFile(words, args[1]));
    catch (Exception e)
    e.printStackTrace();
    // static helper methods
    * Reads a file into a HashMap. The file should contain lines of the format
    * "key\tvalue\n"
    * @returns a hashmap of the given file
    @SuppressWarnings("unchecked")
    private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    HashMap map = null;
    try
    in = new BufferedReader(new FileReader(filename));
    String line;
    map = new HashMap();
    while ((line = in.readLine()) != null)
    String[] fields = line.split("
    t", 2);
    if (fields.length != 2) continue; //just ignore "invalid" lines
    map.put(fields[0], fields[1]);
    finally
    if(in!=null) in.close(); //may throw IOException
    return(map); //returning a reference to local variable is safe in java (unlike C/C++)
    * Process the given file
    * @returns String contains the whole file.
    private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    StringBuffer out = null;
    try
    in = new BufferedReader(new FileReader(filename));
    out = new StringBuffer();
    String line = null;
    while( (line=in.readLine()) != null )
    out.append(SearchAndReplaceWordsInText(words, line)+"\n");
    finally
    if(in!=null) in.close(); //may throw IOException
    return out.toString();
    * Replaces all occurrences in text of each key in words with it's value.
    * @returns String
    private static String SearchAndReplaceWordsInText(Map words, String text)
    Iterator it = words.keySet().iterator();
    while( it.hasNext() )
    String key = (String)it.next();
    text = text.replaceAll("\\b"key"
    b", (String)words.get(key));
    return text;
    * @returns: s with the first letter capitalized
    String capitalize(String s)
    return s.substring(0,0).toUpperCase() + s.substring(1);
    }... here's the head of my pirate_words_map.txt
    hello               ahoy
    hi                    yo-ho-ho
    pardon me       avast
    excuse me       arrr
    yes                 aye
    my                 me
    friend             me bucko
    sir                  matey
    madam           proud beauty
    miss comely    wench
    where             whar
    is                    be
    are                  be
    am                  be
    the                  th'
    you                 ye
    your                yer
    tell                be tellin'

  • Hello can anybody  help me to build an interface

    hello can you help me to build an interface that can work with this english to private talk converter code
    import java.util.Map;
    import java.util.HashMap;
    import java.util.Iterator;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.io.BufferedReader;
    import java.io.FileReader;
    public class Translate
    public static void main(String [] args) throws IOException
    if (args.length != 2)
    System.err.println("usage: Translate wordmapfile textfile");
    System.exit(1);
    try
    HashMap words = ReadHashMapFromFile(args[0]);
    System.out.println(ProcessFile(words, args[1]));
    catch (Exception e)
    e.printStackTrace();
    // static helper methods
    * Reads a file into a HashMap. The file should contain lines of the format
    * "key\tvalue\n"
    * @returns a hashmap of the given file
    @SuppressWarnings("unchecked")
    private static HashMap ReadHashMapFromFile(String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    HashMap map = null;
    try
    in = new BufferedReader(new FileReader(filename));
    String line;
    map = new HashMap();
    while ((line = in.readLine()) != null)
    String[] fields = line.split("\\t", 2);
    if (fields.length != 2) continue; //just ignore "invalid" lines
    map.put(fields[0], fields[1]);
    finally
    if(in!=null) in.close(); //may throw IOException
    return(map); //returning a reference to local variable is safe in java (unlike C/C++)
    * Process the given file
    * @returns String contains the whole file.
    private static String ProcessFile(Map words, String filename) throws FileNotFoundException, IOException
    BufferedReader in = null;
    StringBuffer out = null;
    try
    in = new BufferedReader(new FileReader(filename));
    out = new StringBuffer();
    String line = null;
    while( (line=in.readLine()) != null )
    out.append(SearchAndReplaceWordsInText(words, line)+"\n");
    finally
    if(in!=null) in.close(); //may throw IOException
    return out.toString();
    * Replaces all occurrences in text of each key in words with it's value.
    * @returns String
    private static String SearchAndReplaceWordsInText(Map words, String text)
    Iterator it = words.keySet().iterator();
    while( it.hasNext() )
    String key = (String)it.next();
    text = text.replaceAll("\\b"+key+"\\b", (String)words.get(key));
    return text;
    * @returns: s with the first letter capitalized
    String capitalize(String s)
    return s.substring(0,0).toUpperCase() + s.substring(1);
    ... here's the head of my pirate_words_map.txt
    hello     ahoy
    hi     yo-ho-ho
    pardon me     avast
    excuse me     arrr
    yes     aye
    my     me
    friend     me bucko
    sir     matey
    madam     proud beauty
    miss     comely wench
    stranger     scurvy dog
    officer     foul blaggart
    where     whar
    is     be
    are     be
    am     be
    the     th'
    you     ye
    your     yer
    tell     be tellin'

    hakimade wrote:
    hello can you help me to build an interface that can work with this english to private talk converter codeYou might want to re-ask this question in such a way that it can be answered.
    Also, when posting your code, please use code tags so that your code will retain its formatting and be readable. To do this, either use the "code" button at the top of the forum Message editor or place the tag &#91;code] at the top of your block of code and the tag &#91;/code] at the bottom, like so:
    &#91;code]
      // your code block goes here.
      // note the differences between the tag at the top vs the bottom.
    &#91;/code]or
    {&#99;ode}
      // your code block goes here.
      // note here that the tags are the same.
    {&#99;ode}Good luck.

  • Error message in trying to use local content in Adobe Community Help of Flash Builder

    Hi,
    I have set my Adobe Community Help application preferences of Flash Builder to 'Display local content only'.to Yes.
    I also disabled my internet connection to use local help content only.
    I get the following error message when trying to access any of the links from Help home page.
    To view the requested page, connect to the Internet or deselect "Display Local Help content only" in Preferences.
    I understand this is due to all the links point online HTTP urls.
    But why cannot the local help content be accessed when it is already downloaded to local and the 'Display local content only' option is set to Yes?
    This saves me a lot ot time otherwise using Adobe Community Help is painful even for a short period of time.
    Thanks,
    Ram Manoj Kongara.

    Hi, Ram -
    To help troubleshoot your problem, can you please do the following:
    In the Adobe Community Help application, go to Edit > Preferences.
    Select Local Content.
    The list of Help packages downloaded locally appear. Make sure that the status of every Help packages reads “Current”. If the status of a Help package reads  "Out-of-Date”, select that Help package, and click Update to download the latest Help package. Note that to do this, you have to be connected to the Internet. Once you fully download the Help packages to your desktop, you can access Help offline.
    One other thing that I would want you to check is the Adobe Community Help Client version that you are using. To check that, in the Adobe Community Help application, go to File > About Adobe Help. The build version should be 3.2.0.610.
    Let me know if this helps. If the issue still persists, we can investigate further.
    Thanks,
    Mallika Yelandur
    Technical writer, Adobe Flash Builder

Maybe you are looking for

  • Ship to Party in Prospective Customer

    Hi All I am facing problem with Prospective Customer. In account group 0005 there is no Ship to, Bill to and Payer as partner. which is logical in this scenario. But when I create a sales document it asks for a Ship to party in the initial screen and

  • Why cann't I make calls even though I have subscri...

    I just subscribed for a month unlimited. I made three calls to China. But after that I cannot call any number no matter it's China or America. Who can help me? Thanks!

  • TS2755 Phone disabled

    Phone has been disabled because someone tried to enter password to many times

  • Photoshop CS5 Repousse & Mac mini

    does anyone have experience with using the Repousse or other 3D functions of photoshop CS5? my pc graphics card won't support it and i'm looking to switch to Mac anyway, but i don't want to buy a Mac mini if it won't support Repousse and other 3D fun

  • Why is there not a customer relations team on the weekend

    i try and get in contact with customer relations on a saturday to find out about my replacment but get told they are closed yet they are the only ones that can help