Weak and concurrent hash map for caching

Hello,
I have written a very simple cache class with both weakness and concurrency benefits. This class is intended to be used as a weak cache in "hot redeploy" capable servers (JBoss or any other).
My implementation uses the (problematic) "double-check" pattern with a reentrant lock and encapsulates a WeakHashMap with WeakReference values (to avoid circular key/value references). Here is the code:
public interface ValueCreator<V> {
     public V create();
public class WeakCache<K, V> {
     private final Lock lock = new ReentrantLock();
     private final Map<K, WeakReference<V>> weakMap;
     public WeakCache() {
          this(16);
     public WeakCache(int initialCapacity) {
          this(initialCapacity, 0.75F);
     public WeakCache(int initialCapacity, float loadFactor) {
          weakMap = new WeakHashMap<K, WeakReference<V>>(initialCapacity, loadFactor);
     public V get(K key, ValueCreator<V> creator) {
          WeakReference<V> ref = weakMap.get(key);
          if (ref == null) {
               lock.lock();
               try {
                    ref = weakMap.get(key);
                    if (ref == null) {
                         ref = new WeakReference<V>(creator.create());
                         weakMap.put(key, ref);
               } finally {
                    lock.unlock();
          return ref.get();
     }One usage of this cache is for session ejb3 lookup:
private static final WeakCache<Class, Object> LOOKUP_CACHE = new WeakCache<Class, Object>();
public static <T> T lookup(final Class<T> serviceClass) {
     T service = (T)LOOKUP_CACHE.get(serviceClass,
          new ValueCreator<Object>() {
               public T create() {
                    String lookup = "myapp/" + serviceClass.getSimpleName() + "/local";
                    try {
                         return (T)(new InitialContext()).lookup(lookup);
                    } catch (NamingException e) {
                         throw new RuntimeException("Could not lookup EJB " + serviceClass + ": " + lookup, e);
     return service;
...2 questions:
1. Is there any issue with concurrent access to this cache ?
2. What happens exactly when the garbage collector wants to free memory with a map with both weak keys and values ?
Some limited tests show that the behavior of this cache fits my needs: the lookup cache is cleared on redeploy and it keeps its key/values pairs otherwise.
Thanks for any comments.
Message was edited by:
fwolff999

I know that DCL is broken under certain circumstances (but I have read it may work with modern JVM and the use of volatile variables for example).
So: is it broken with this specific implementation and if so, what should be done to make it work ?
The getter method is potentially setting a value (like in ConcurrentHashMap.putIfAbsent) and it uses a ValueCreator in order to actually create the value only if it is not already present in the map.

Similar Messages

  • Passing a Hash Map in a Custom Workflow.

    I have a workflow WF_CUSTOM_TXT which inputs credentials such as resource name, type, connection string and then I am passing the attributes as a Hash Map: -
    Map attributes =new HashMap();
    attributes.put("firstname", "Nakul");
    attributes.put("lastname", "Sharma");
    When I launch the process in the java code which should pass the Hash Map for the workflow WF_CUSTOM_TXT, but i am unable to do so as I declared the attribute in the wrkflow which can be defined as a String. So mismatch occurs????
    Another question that I have is that is it possible for us to pass a set of Multi values attributes as a Hash to a workflow and receive the same and then extract individual elements out of the hash toallocate to variables in the WF. Please provide any suggestions!!!!!!!!

    can you plz share the code, so that i can get what are you doing and where you stuck.
    and also try to initialize the variable with hashmap objcet and the see

  • How to create a dicitionary using hash map.

    Hi All,
    I want to create a dictionary using hash map where in i can add new words and there meaning. I have written some code But I am not happy with this. Can you suggest me how to add the words and there meanings to the hash map.
    I am not able to add the words and there meaning to the hash map.
    for this i tried creating a dictionary class.
    // Using hashmap
    import java.util.*;
    public class Dictionary
        public static void main(String[] args)
            // Create a hash map
            HashMap hm = new HashMap();
            // put elements to the map
            hm.put("Abode: ", "Home");
            hm.put("Balance: ", "An intrument to measure or weigh");
            hm.put("Car: ", "Automobile");
            hm.put("Dinner: ","Last meal of the day generally had after evening and before sleeping");
            hm.put("Embossed: ", "Engraved kind");
            Set set = hm.entrySet();
            Iterator i = set.iterator();
            while (i.hasNext())
                Map.Entry me = (Map.Entry) i.next();
                System.out.print(me.getKey() + ": ");
                System.out.println(me.getValue());
            System.out.println();
    }This is the other Dictionary class which i created.
    public class Main_Dictionary
        public static void main(String[] args)
            Content_Dictionary cd = new Content_Dictionary();
            cd.getContent_Dictionary("Abode", "Home");
            cd.displayValues();
    class Content_Dictionary
        String word, meaning;
        Content_Dictionary()
            word = "a";
            meaning = "b";
        Content_Dictionary(String x, String y)
            word = x;
            meaning = y;
        void getContent_Dictionary(String w, String m)
            word = w;
            meaning = m;
        void displayValues()
            System.out.print(word + ": ");
            System.out.println(meaning);
    }If i create an interface containing all the words and there meaning
    public interface Words_Dictionary
        String Abode = "Home";
        String Dark = "Lacking brightness";
        String Balance = "An intrument to measure or weigh";
        String Car = "Type of Automobile";
        String Dinner = "Last meal of the day";
        String Embossed  = "Engraved kind";
        String Adroit = "SkillFul";
    }and then create a another class which implements this interface, but how should i add these words and there meaning in the hashmap.

    I tried creating word document but i was unable to
    figure out how to do the operations on the word
    document and its content,
    So This is what i could come up with, i just created
    one class Dictionary , now I am able to search for
    the meaning of the word specified by me, and I am
    able to print all the words and there meanings added
    to the hashmap, but i am not able to figure out how
    to add a new word and the meaning in the hashmap and
    how to find is a word is there or not...May I suggest a slightly different approach?
    Do not create a String ==> String mapping, but a String ==> List<String> mapping. And do NOT place everything inside your main method.
    Here's a small demo:
    import java.util.ArrayList;
    import java.util.Map;
    import java.util.HashMap;
    import java.util.List;
    public class Dictionary {
        private Map< String, List<String >> dictionary;
        public Dictionary() {
            dictionary = new HashMap< String, List<String >>();
        public void addWord(String base, String meaning) {
            List<String> allMeanings = dictionary.get(base);
            if(allMeanings == null) { // if null, there is no entry mapped to 'base' yet: create a new one
                List<String> newMeanings = new ArrayList<String>();
                newMeanings.add(meaning);
                dictionary.put(base, newMeanings);
            } else {
                allMeanings.add(meaning);
        public List<String> search(String base) {
            // your code here
            return null;
        // ... other methods ...
        public String toString() {
            StringBuilder strb = new StringBuilder();
            for(Map.Entry< String, List<String >> e : dictionary.entrySet()) {
                strb.append(e.getKey());
                strb.append(" : ");
                strb.append(e.getValue());
                strb.append('\n');
            return strb.toString();
        public static void main(String[] args) {
            Dictionary dict = new Dictionary();
            dict.addWord("Abode", "Home");
            dict.addWord("Abode", "House");
            dict.addWord("Car", "Automobile");
            dict.addWord("Car", "Vehicle");
            System.out.println(dict);
    }Good luck.

  • Google maps for flash been Deprecated !

    Hello. i just wana notify the comunity about a serious step tooken from google to kill the maps for flash, because seems like they can not handle them.
    I would like to hear Adobe opinion - can Adobe do their developers a favor and asign a programmers to took close deal with google and continue the maps for flash ?
    This is not a simple issue, it will be a vital for the future development of many things connected to Adobe and Google.
    Please consider the question carefully.

    http://code.google.com/apis/maps/documentation/flash/
    "Note: The Google Maps API for Flash has been officially deprecated as of September 2, 2011. The API will continue to work as per ourdeprecation policy, but we encourage you to migrate your applications to version 3 of the Maps JavaScript API."
    The statement is perfectly LOL.
    And seems like google can not pay 2-3 more developers to took care for thoose API,
    The forum comunity related to this API vould like to ask if can Adobe took care on it because they have proven as a good team of developers already.

  • Problem accessing /config_general/null/Default.action   Reason:There is no Action mapped for namespace/ config_general and action name default

    in use:
    vRO 5.1
    eclipse 3.7.2
    vRo plug-sdk 5.1
    steps:
    1.create a plug-in project from samples(choose solar system)
    2.find the dar package and upload it by vRo configuration
    3.vRo configuration said upload successfully,but the solar system configuration is not properly configued..
    problem:
    Problem accessing /config_general/null/Default.action   Reason:There is no Action mapped for namespace/ config_general and action name default
    How to solve it??
    Thanks so much!!

    There was problem from crm side...its working now..

  • How can i configure Distributed cache servers and front-end servers for Streamlined topology in share point 2013??

    my question is regarding SharePoint 2013 Farm topology. if i want go with Streamlined topology and having (2 distribute cache and Rm servers+ 2 front-end servers+ 2 batch-processing servers+ cluster sql server) then how distributed servers will
    be connecting to front end servers? Can i use windows 2012 NLB feature? if i use NLB and then do i need to install NLB to all distributed servers and front-end servers and split-out services? What will be the configuration regarding my scenario.
    Thanks in Advanced!

    For the Distributed Cache servers, you simply make them farm members (like any other SharePoint servers) and turn on the Distributed Cache service (while making sure it is disabled on all other farm members). Then, validate no other services (except for
    the Foundation Web service due to ease of solution management) is enabled on the DC servers and no end user requests or crawl requests are being routed to the DC servers. You do not need/use NLB for DC.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • Java mapping for Remove and Add of  DOCTYPE Tag

    HI All,
    i have one issue while the Java mapping for Remove and Add of  DOCTYPE Tag   in Operation Mapping .
    it says that , while am testing in Configuration Test "  Problem while determining receivers using interface mapping: Error while determining root tag of XML"
    Receiver Determination...
    error in SXMB MOni
    " SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="RCVR_DETERMINATION">CX_RD_PLSRV</SAP:Code>
      <SAP:P1>Problem while determining receivers using interface mapping: Error while determining root tag of XML: '<!--' or '<![CDATA[' expected</SAP:P1>
    plz provide solutions
    Thanks in advance.

    Hi Mahesh,
    I understand, you are using extended Receiver Determination using Operational Mapping (which has Java Mapping). And, there is an error message u201CError while determining root tag of XMLu201D, when you are doing configuration test.
    Can you please test, the Operational Mapping (which has Java Mapping) separately in ESR, with payload which is coming now. It should produce a XML something like this [Link1|http://help.sap.com/saphelp_nwpi711/helpdata/en/48/ce53aea0d7154ee10000000a421937/frameset.htm]
    <Receivers>
    <Receiver>
      <Party agency="016" scheme="DUNS">123456789</Party>
      <Service>MyService</Service>
    </Receiver>
    <Receiver>
      <Party agency="http://sap.com/xi/XI" scheme="XIParty"></Party>
      <Service>ABC_200</Service>
    </Receiver>
    </Receivers>
    If it is not (I Think it will not), then there is some problem in Java Mapping coding. Please correct it. Last option, if your Java code is small in length; you may paste it here, so that we can have a look at the cause of issue.
    Regards,
    Raghu_Vamsee

  • Mapping and querying Custom Objects for a Contact with REST Api

    Hello All,
    We are hoping to get some details on managing DataCard set through REST APIs. Our implementation goal is to create Contacts and add Custom object for each Contact, or to be precise, add a DataCard Set for each Contact.
    At the moment, to associate a DataCard Set (or Custom Object) to an existing contact, we are supplying following custom object fields during creation of Custom Object:
    new CustomObjectField 
                                                                    name = "MappedEntityType",
                                                                    dataType = Enum.GetName(typeof(DataType), DataType.numeric),
                                                                    type = "CustomObjectField",
                                                                    defaultValue = "0"
                                                             new CustomObjectField
                                                                    name = "MappedEntityID",
                                                                    dataType = Enum.GetName(typeof(DataType), DataType.numeric),
                                                                    type = "CustomObjectField",
                                                                    defaultValue = "<ContactId>"
    Is this the correct approach? This is Based on the information provided here: http://topliners.eloqua.com/community/code_it/blog/2012/05/31/eloqua-api-how-to-mapping-a-data-card-to-an-entity.
    Would the REST API allow us to query the CustomObjects using the MappedEntityId value for later updates? If so, any pointers on how we approach that?
    Thanks in ad.

    Either the MappedEntityID field is not available or I do it wrong, Eloqua is ignoring the field and does not map the custom record with the unique Contact ID
    {"type":"CustomObjectData","ContactID":"8829509","fieldValues":[{"id":"195","value":"[email protected]"},{"id":"220","value":"a0KJ000000387QvMAI"},{"id":"191","value":"001J000001OrL77IAF"},{"id":"193","value":"NowTV MPP"},{"id":"194","value":"8829509"},{"id":"196","value":"Andreas"},{"id":"197","value":"Wolf"},{"id":"198","value":"003J00000145lkBIAQ"},{"id":"210","value":"777666555"},{"id":"199","value":"gbp"},{"id":"200","value":"0"},{"id":"215","value":"0"},{"id":"201","value":"999111999"},{"id":"214","value":"111111"},{"id":"202","value":"222222"},{"id":"204","value":"now"},{"id":"203","value":"xmas"},{"id":"205","value":"no description"},{"id":"206","value":"test"},{"id":"218","value":"holidays"},{"id":"219","value":"PPV-0878545"},{"id":"213","value":"N"},{"id":"212","value":"myself"},{"id":"209","value":"now tv"},{"id":"192","value":"1417542120"},{"id":"207","value":"1417542120"},{"id":"216","value":"1417542240"},{"id":"217","value":"1417542240"},{"id":"211","value":"1417542240"}]},"MappedEntityID":"003J00000145lkBIAQ"}
    Response
    DEBUG|Response------{"type":"CustomObjectData","id":"81720","fieldValues":[{"id":"195","value":"[email protected]"},{"id":"220","value":"a0KJ000000387QvMAI"},{"id":"191","value":"001J000001OrL77IAF"},{"id":"193","value":"NowTV MPP"},{"id":"194","value":"8829509"},{"id":"196","value":"Andreas"},{"id":"197","value":"Wolf"},{"id":"198","value":"003J00000145lkBIAQ"},{"id":"210","value":"777666555"},{"id":"199","value":"gbp"},{"id":"200","value":"0"},{"id":"215","value":"0"},{"id":"201","value":"999111999"},{"id":"214","value":"111111"},{"id":"202","value":"222222"},{"id":"204","value":"now"},{"id":"203","value":"xmas"},{"id":"205","value":"no description"},{"id":"206","value":"test"},{"id":"218","value":"holidays"},{"id":"219","value":"PPV-0878545"},{"id":"213","value":"N"},{"id":"212","value":"myself"},{"id":"209","value":"now tv"},{"id":"192","value":"1417542120"},{"id":"207","value":"1417542120"},{"id":"216","value":"1417542240"},{"id":"217","value":"1417542240"},{"id":"211","value":"1417542240"}]}
    Eloqua:
    Name: PPV-0878545
    Unique Code: a0KJ000000387QvMAI
    Status Registered
    Created Date 12/22/2014 12:44:49 PM
    Mapped NO
    Any Idea how to map this to a contact
    Entity Type is Contacts
    Entity Field is SFDC Contact ID

  • NAT configuration and Port Mapping for xBox

    I'm looking for help with port mapping to open up the NAT for an xBox One. I'm working with the following network devices:
    xBox One
    DSL Modem: Embarq (ZyXEL) 660R series
    Airport Extreme version 7.7.3
    I understand the following from researching the issue:
    The default settings for both devices block the ports needed for xBox Live.
    Airport Extremes are not on the compatible list for xBox.
    Port Mapping is better then creating a DMZ for the xBox.
    The xBox needs its own manually set IP address.
    I switched my Network>Router Mode from Off (Bridge Mode) to DHCP and NAT. I then created a DHCP Reservation and the Port Settings for that IP.
    After doing this, the Airport would restart and display a warning - Double NAT. I figured this was because the 660 settings showed the NAT Mode to be SUA Only. The Edit Details link displayed an empty table where you edited the SUA/NAT Server Set. I switched from NAT Mode>SUA Only to None. So there was my Double NAT and I would have thought that would have removed one.
    I also disabled the Firewall and Enabled the UPnP.
    After restarts the Airport continued to display the Double NAT error. However, with the 660's NAT Mode set to None, the Internet was not there. Web browsers and email accounts replied with server not found.
    Only with the 660 set to SUA Only and the Airport in Bridge Mode is the Internet accessible. I now have the details for the SUA filled out for the xBox's IP address and ports.
    Hypothesis
    Since both devices are acting as DHCP servers the port mapping is not working. Rather then have the 660 distribute IP addresses and then having the Airport distribute another range of numbers, I need to have both devices bridge and distribute one range of numbers. Currently the 660 is using the 192.168 range and the Airport is using the 10.0 range.
    Am I correct? Any thoughts and suggestions are welcome.

    Port forwarding through a double NAT.. is near impossible.. !!
    And the xbox is so attuned to using UPNP it is very hard not to.. even port mapping is not a great fix. Since apple decided gamers did not count as users for Airports.. I think honestly it is best to bypass the airport and stick to upnp from the modem router.
    What method of authentication does your ISP use? Because it is really better to use one router.
    And in fact the router should be the Zyxel. If you plug the Xbox to the Zyxel running in full router mode, with the airport removed from the network does it work and open NAT??
    If not replace the Zyxel with a modern listed router that is xbox compatible and bridge the airport to it.

  • How can I get rid of ios6 ? I have had this iPad for less than 2 weeks and,ade the mistle of "upgrading" to ios6 and now my map is completely useless.  Feel like I have been robbed

    how can I get rid of ios6 ? I have had this iPad for less than 2 weeks and made the mistake of "upgrading" to ios6 and now my map is completely useless.  Feel like I have been robbed

    There are alternatives. But none of them have Google street view, able to work on iOS 6. Apple should have offered this as a beta version, for a few more months instead of inflicting us with an inferior product. This iPad will probably be my last Apple product. A shame, because until last a few days ago, I thought the iPad and iPhone were fantastic.
    Apple should quit their petty squabbling with, Google and Samsung and concentrate on supplying the best product.
    Google and Samsung must be enjoying this particular fiasco.

  • MAP for Finished and Semi Finished goods

    Dear Friends,
    Please let me know;
    1. If Finished and Semi finsihed goods are maintained with price indicator 'S' and all are inhouse production then SAP updata moving average price or these material or not ?
    2. If SAP updata MAP for finished and semi-finished,  later can we change map manually or not ? if yes How ?
    3. Is there any way to stop updata of map by sap in case of finsihed and semifinished goods.
    Actually according to my product costing variant, I dont need any price in map of FG and SFG. Kindly give me your expert openion on this issue.
    Thanks
    Ravi

    Hi
    1. If you maintain price control S for inhouse produced finished product also, system updates moving average price with resepect stock and value of production (may be period wise production cost may be varying). But this is statistical.
    2. You can change price control from S to V if you require. You need to change first in material type and then change in material master.
    3. If the value is getting updated also it will have no impact. In case of product cost variant also it will get updated.
    Thanks

  • How to acces and display datas storaged in cache for a SUP 2.0 workflow?

    HI to all.
    I have an application with a item menu which obtains data thought a online request. the result is shown is a listview.
    My problem is when my BlackBerry has no conection ( offline scenario). When I select the menu item, I obtain an error.
    How to acces and display datas storaged in cache for my MBO? I have read that I can use getMessageValueCollection in custom.js to access to my datas but once I get the datas, How can associate those datas to a Listview like a online request?? Do i have to develop my own screen in html or how?
    Thanks.

    I'm not entirely clear on what you mean by "cache" in this context.  I'm going to assume that what you are really referring to is the contents of the workflow message, so correct me if I'm wrong.  There is, in later releases, the ability to set an device-side request cache time so that if you issue an online request it'll store the results in an on-device cache and if you subsequently reissue the same online request with the same parameter values within that timeout period it'll get the data from the cache rather than going to the server, but my gut instinct is that this is not what you are referring to.
    To access the data in the workflow message, you are correct, you would call getMessageValueCollection().  It will return an object hierarchy with objects defined in WorkflowMessage.js.  Note that if your online request fails, the data won't magically appear in your workflow message.
    To use the data in the workflow message to update a listview, feel free to examine the code in the listview widgets and in API.js.  You can also create a custom listview as follows:
    function customBeforeNavigateForward(screenKey, destScreenKey) {
         // In this example, we only want to replace the listview on the "My Approvals" screen    
         if (destScreenKey == 'My_Approvals'){
              // First, we get the MessageValueCollection that we are currently operating on
              var message = getCurrentMessageValueCollection();
              // Next, we'll get the list MessageValue from that MessageValueCollection
              var itemList = message.getData("LeaveApprovalItem3");
              // Because its a list, the Value of the MessageValue will be an array
              var items = itemList.getValue();
              // Figure out how many items are in the list
              var numOfItems = items.length;
              // Iterate through the results and build our list
              var i = 0;
              var htmlOutput = '<div><ul data-role="listview" data-theme="k" data-filter="true">';
              var firstChar = '';
              while ( i < numOfItems ){
                   // Get the current item. This will be a MessageValueCollection.
                   var currItem= items<i>;
                   // Get the properties of the current item.
                   var owner = currItem.getData("LeaveApprovalItem_owner_attribKey").getValue();
                   var type = currItem.getData("LeaveApprovalItem_itemType_attribKey").getValue();
                   var status = currItem.getData("LeaveApprovalItem_itemStatus_attribKey").getValue();
                   var startDate = currItem.getData("LeaveApprovalItem_startDate_attribKey").getValue();
                   var endDate = currItem.getData("LeaveApprovalItem_endDate_attribKey").getValue();
                   // Format the data in a specific presentation
                   var formatStartDate = Date.parse(startDate).toString('MMM/d/yyyy');
                   var formatEndDate = Date.parse(endDate).toString('MMM/d/yyyy');
                   // Decide which thumbnail image to use
                   var imageToUse = ''
                        if (status == 'Pending'){
                             imageToUse = 'pending.png';
                        else if (status == 'Rejected'){
                             imageToUse = 'rejected.png';
                        else {
                             imageToUse = 'approved.png';
                   // Add a new line to the listview for this item
                   htmlOutput += '<li><a id ="' + currItem.getKey() + '" class="listClick">';
                   htmlOutput += '<img src="./images/' + imageToUse + '" class="ui-li-thumb">';
                   htmlOutput += '<h3 class = "listTitle">' + type;
                   htmlOutput +=  ' ( ' + owner + ' ) ';
                   htmlOutput += '</h3>';
                   htmlOutput += '<p>' + formatStartDate + ' : ' + formatEndDate + '</p>';
                   htmlOutput += '</a></li>';
                   i++;
              htmlOutput += '</ul></div>';
              // Remove the old listview and add in the new one.  Note: this is suboptimal and should be fixed if you want to use it in production.
              $('#My_ApprovalsForm').children().eq(2).hide();
              $('#My_ApprovalsForm').children().eq(1).after(htmlOutput);
              // Add in a handler so that when a line is clicked on, it'll go to the right details screen
              $(".listClick").click(function(){
                   currListDivID = $(this).parent().parent();
                   $(this).parent().parent().addClass("ui-btn-active");
                   navigateForward("Request_Details",  this.id );
                   if (isBlackBerry()) {
                        return;
         // All done.
         return true;

  • Surrogate Key and Map for Cube

    Hi
    I am new to Data Warehousing and am trying to use OWB 11g.
    I am trying to create dimensions with multiple levels. When I create more than one level it need to have surrogate as well business key for each dimension level. But I can create only one surrogate in the dimension, there is no option to create multiple surrogate keys in the same dimension. so what am I missing?
    My second question is regarding cube. Do I need to create a Mapping for a cube? if yes, should I move the data to the cube from the dimensions? and where will the measures come from? do i need to load the measures or they will be calculated automatically?
    please reply...
    regards
    Arif

    hi
    Got it, Yes that was the reason,
    The table was not properly deployed after the dimension was modified.
    Anyway, the describe of the table is as follows
    describe arif.QUESTION_DIM
    Name Null Type
    DIMENSION_KEY NOT NULL NUMBER
    IGV_ID NUMBER
    PER_ID NUMBER
    DIM_ID NUMBER
    IGO_ID NUMBER
    INQ_ID NUMBER
    ID NUMBER
    DIM_ORDEM NUMBER
    DIM_AMBITO VARCHAR2(3)
    DIM_NOME VARCHAR2(150)
    10 rows selected
    Now, I am having another problem,
    when, I deploy the Map to load the data from three different tables, it gives the following problem
    Name               Action               Status          Log
    QUESTION_MAP          Create               Warning          ORA-06550: line 297, column 25:
                                            PLS-00302: component 'ID' must be declared
    QUESTION_MAP          Create               Warning          ORA-06550: line 1153, column 11:
                                            PL/SQL: SQL Statement ignored
    QUESTION_MAP          Create               Warning          ORA-06550: line 1155, column 15:
                                            PL/SQL: ORA-00904: "QUESTION_DIM"."ID": invalid identifier
    QUESTION_MAP          Create               Warning          ORA-06550: line 1155, column 31:
                                            PLS-00302: component 'ID' must be declared
    QUESTION_MAP          Create               Warning          ORA-06550: line 233, column 1:
                                            PL/SQL: SQL Statement ignored
    QUESTION_MAP          Create               Warning          ORA-06550: line 2539, column 11:
                                            PL/SQL: SQL Statement ignored
    QUESTION_MAP          Create               Warning          ORA-06550: line 2541, column 15:
                                            PL/SQL: ORA-00904: "QUESTION_DIM"."ID": invalid identifier
    QUESTION_MAP          Create               Warning          ORA-06550: line 2541, column 31:
                                            PLS-00302: component 'ID' must be declared
    QUESTION_MAP          Create               Warning          ORA-06550: line 297, column 9:
                                            PL/SQL: ORA-00904: "QUESTION_DIM"."ID": invalid identifier
    Edited by: user643560 on Oct 22, 2008 9:38 AM

  • How to use offline map for windows store app using c# and xaml

    Hi friends,
    I want to integrate offline map in my windows store app but I am not able to achieve that.
    Below is my requirement:
    When a user wants to go somewhere where she/he doesn't want to use wi-fi or mobile data but wants to use map to assist her/him to roam around. For this I want to give an option to download the map for that region/area before leaving for that place and there
    she/he can use map even in offline.
    Is it possible that I can achieve this using Bing maps?
    If yes then tell me the processes to follow.
    If no then can I achieve this using "Here" or by using any other API or by tweaking any way?
    Note: I am showing maps in case of online and user can search for directions or any places in that. I am using Bing maps for that.
    Thanks,
    S.Sandeep

    Hi Sandeepmsandy,
    There is no available code sample for this scenario. You may write your own.
    Step 1: Get pdf URL from sqlite database. Please refer to the following MSDN blog and see a code sample.
    http://blogs.msdn.com/b/robertgreen/archive/2012/11/13/using-sqlite-in-windows-store-apps.aspx. Note, you need to retarget the project to 8.1 and then get two sqlite packages from NuGet before building this sample.
    Step 2: Use some special classes to get file from serer.
    HttpWebRequest can help download small pdf files. For more information to see
    https://social.msdn.microsoft.com/Forums/windowsapps/en-US/de96a61c-e089-4595-8349-612be5d23ee6/download-file-with-httpwebrequest?forum=winappswithcsharp. It’s easy for use, but if you want to download the larger or many files, it’s recommend to use
    BackgroundTransfer namespace. The classes in this namespace provide a power way to transfer files in the background. See a code sample from MSND.
    https://code.msdn.microsoft.com/windowsapps/Background-Transfer-Sample-d7833f61.
    Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place. Click HERE to participate
    the survey.

  • Ovi map for other country downloaded and installed...

    I've used the Ovi Suite 2.2.0.245 and connected with N900 but selected PC suite mode instead of Mass storage. I read alot that you have to select Mass storage for N900, but Ovi Suite won't then be connected with my phone, but works with PC suite.
    I wanted to transfer country maps to the phone so I can use it offline. Selected the Map and downloaded and it said transfered to phone...so everything seems good. But when I go to open those maps on the phone...I can't find them anywhere at all! I'm not sure where they are.....I've check the 'ovi map', then the 'cities' folder but nothing. There are other files there but not titled with the cities i've downloaded. I tried to open those files anyways (having a "?" as their icon) and then selected I think 'Application' or something as ways to open the file.....then needed to download but 0kb...??? it then said unable to download, the file could be corrupted. So now..I'm stuck.
    I don't know where the maps were transfered to. Oh and I check on the Ovi suite Map tab and selected my device, and it should alllll the cities and countries listed in my device (phone) already....but I can't find/open them on the phone. Much help and guidance would be appreciated!
    Thanks in advance.
    Solved!
    Go to Solution.

    Thanks for reply. I did check the cities folder and it's not there...I've downloaded New York and cannot find it. Also, the folders I saw were all a few kb and not the appropriate size.
    I went to ovi maps on the n900 and only showed me where I am, I wanted to open new york map but don't know where and how. I clicked on search and entered new york but then ask me to connect to the internet. It did and it worked but then that means I have to connect.
    It said I can be offline for N900:
    http://www.nokia.com.au/get-support-and-software/download-software/maps-support/how-to/maps-for-n900
    I thought it can be veiwed offline, so how can I? I wanted to open the map when overseas but if there's no internet connection and I have transfered the map on the phone previously, I won't be able? =(

Maybe you are looking for

  • XSLT  explanation

    ....Our first template matches "/", the XPath expression for the document's root element. <xsl:template match="/">         // line1 <xsl:apply-templates select="greeting"/> // line2 </xsl:template>i have been stuck. actually, i want to know the role

  • Forcing JFrame to lose its focus programatically

    Hello everyone, I have a JFrame with a button over it. Now I wants that when I click on the button, my JFrame should lose its focus. Can anybody tell me whether it is possible in java or not? Thanks in advance.

  • Drag and Drop to Batch Convert Videos Using FFMPEG

    I've created this simple Applescript that will run an FFMPEG command in the Terminal (which I want to show so that I can see the progress) on files dropped on the MTS to Cropped MPG.app icon: on open filelist           repeat with i in filelist      

  • CANNOT USE MY ISIGHT AND VIDEO CONFRENCE NEED SERIOUS HELP !!!!

    I'VE BEEN TRYING TO USE VIDEO CONFRENCE AND I KEEP GETTING A DID NOT RESPOND ERROR. I OPENED THE REQUIRED PORTS ON MY CPU . IM USING A NETGEAR RANGEMAX 240 WIRELESS ROUTER TO CONNNECT TO THE INTERNET. IM AT MY ENDS TRYING TO FIGURE OUT THE PROBLEM. I

  • Jpegs saved via Mac won't open in Windows

    I use Nikon transfer on my Macbook pro and save my pictures to a Western Digital passport external hard drive (that I also use in Windows applications). When I attach the drive to any Windows pc/laptop, I can only see and open whatever was created on