About Surrogate Key and Dimension Key on OWB 10.2

Hi, everyone.
I am using OWB 10.2 and I have a question about Surrogate key and Dimension Key.
I indicated the foreign key as VARCHAR2 type in Fact Table and Dimension Key as VARCHAR2 type is operated as Primary key in Dimension Table. I made Single Level in Dimension Table.
I know that Dimension Key stores the surrogate ID for dimension and is the primary key of the table. Also, Surrogate ID should be only NUMBER type.
So, in this case, Surrogate ID is NUMBER type
Dimension key should be NUMBER type to store the surrogate ID.
But, Dimension key also should operate the primary to relate Foreign key as VARCHAR2 type.
How I can solve this confusing condition?
Please let me know that.
JWS

Hi JWS,
From a SQL point of view it should not be a problem to join a NUMBER field to a VARCHAR2 field because during execution there will be an implicite cast for the NUMBER value to a VARCHAR2 value. See the example below.
   SELECT * FROM DUAL
   WHERE   1 = '1'From an OWB point of view it is not possible to have a Dimension with an NUMBER value Key that has a relation to a VARCHAR2 value Foreign key in a Fact table. This is caused due to the creation of a Fact table in OWB in which the Foreign keys in it are build from de Dimension tables that refer to them.
You will loose the reference to the Dimension when changing the type of the Foreign Key.
To resolve this issue I would advise you to use a Sequence that generates your Surrogate Key (NUMBER type) for the Dimension table and store it in the Primary Key Column (VARCHAR2 type).
When validating the mapping you will get a warning, but when executing this should give no problems.
Regards,
Ilona

Similar Messages

  • Difference between Dimension Id and Dimension Key

    I am reading the third chapter of Rittman's OBIEE book on design of Repository.
    It says while building the BMM, don't drag the dimension Id columns from physical layer to logical layer as the BI Server takes care of the join for you but make sure you drag across the dimension key columns as you will need these later on to create your logical table keys.
    Can someone enlighten me on what is the difference between a dimension id and dimension key (may be with an example).
    Thanks.

    Besides the theory says that a fact table can reference any level of a dimension, I couldn't do it with OWB. I don't know if there is a specific way to do that, but I only could assign a dimension detail level to a fact table.
    The ID's can have different values when I use a hierarchy in a dimension. OWB generates automatically negative ID's for the more summarized levels.
    For example, a product dimension with 2 levels: category and detail. If the product has 4 categories and 20 products (detail level), the table has 4 rows for categories with negative id's. Each row has a category and the fields specific for detail level are empty. The table will have other 20 rows for the detail level, with all fields filled, and all id's positive. The table will have 24 rows in the end.

  • Primary Key and Chronological Key for Time Dimension

    Could someone please shed light whether it's better to use normal PK or Calendar Date (which is a chronological key on the most detailed level). I tried both and haven't noticed any difference. But my understanding is that I still need to have the PK key on the most detailed level in time hierarchy.
    Thanks

    Matt,
    the PK of the Time Dimension is a regular sequence numeric key. I have it defined as a logical PK for the dimension. However, I guess I was talking about hierarchy key. I tested it either way and the query time is the same. So I guess it doesn't really matter.
    --------Year
    Year (chronological key and primary key)
    ------------------Quarter
    Quarter (key)
    Quarter+Year (primary key, chronological key)
    ---------------------------------Day Detail
    PK (key)
    Date (primary key , chronological key)
    I hope it makes sense.

  • Is anyone else having the finish rub off of the keys on their macbook? I've had mine for about 6 months and several keys look like the finish is wearing through. I went to the local genius bar today and the techs said they'd never seen this before.

    Is anyone else having the finish rub off of the keys on their macbook? I've had mine for about 6 months and several keys look like the finish is wearing through. I went to the local genius bar today and the techs said they'd never seen this before.

    Some people have seen their aluminum uni-body discoloring due to body oils.  Go figure.
    Normally putting anything over the keys/aluminum will hurt heat disspation, but you may need to use keyboard covers.
    Or save up $500/year for new keyboards.
    Neither is supposed to be a sarcastic answer.  Either one could end up being the solution.
    Good luck with it.

  • Diff b/w surragate keys and primary keys

    Can any one of u pls explain the difference between primary key and surragate keys,pls explain me with simple example

    Hi rajesh,
    surrogate key: For every master data record, system create a SID (Surrogate ID). If that particular master data record is used in infocube, system store the SID corresponding to that master data in dimension table and the dimension id of the dimension table is stored in infocube Fact 'F' table.
    Primary key: while creating a table we will select unique field and create as primary key..for eg empid acts as a unique key (primary key) for emp table. through this primary key we can identify the table to get the data from the table.
    i hope this helps u.
    regards
    anil

  • Hardware key and license key

    Hi All,
    I have a question about the HW key and license key for SAP on Solaris.
    As currently, we would like to replace the existing hard-disk with a larger one.
    And i would like to know that, can we using the same license generated before, or we need to generate a new one?
    Regards,
    Cheung

    Hi Wing,
    Got no documentation explicit about this, only personal experience. You can look at note 94998, and perhaps this PDF: https://websmp106.sap-ag.de/~sapidb/011000358700005997252005
    Best Regards,
    JC Llanes.

  • How to transfer database table contain null values, primary key, and foreign key to the another database in same server. using INSERT method.

    how to transfer database table contain null values, primary key, and foreign key to the another database in same server. using INSERT method.  thanks

    INSERT targetdb.dbo.tbl (col1, col2, col3, ...)
       SELECT col1, col2, col3, ...
       FROM   sourcedb.dbo.tbl
    Or what is your question really about? Since you talke about foreign keys etc, I suspect that you want to transfer the entire table definition, but you cannot do that with an INSERT statement.
    Erland Sommarskog, SQL Server MVP, [email protected]

  • Any fix on home key and search key not working?

    I got this phone about a month ago but never had time to really learn it until now and so far I am not impressed. Should have stayed with HTC and too late to change. My home key and search key do not work. I have tried a reset and nothing. Anyone have a fix for this? And his 4G thing? ya. Again my 3g HTC worked better.

    The Droid Razr doesn't have a user-removable battery.
    I also encountered an issue where my home key got reassigned to another function, such as not working at all and then only opening a "choose for default operation" menu that didn't give me an option to make it a home key again.  I found it was from downloading a launcher from the play store and it's corresponding unlocker.  It basically took over my phone and severely limited the UI.  After uninstalling the software there was still a resident program that wouldn't stop running and it wasn't detected by my task manager (a virus).   I had to go through a complete "factory default' reset - which required me to re-install all my market apps.
    To do a factory reset, go to Menu>Settings>Privacy>Factory data reset.
    But first you may want to go to Menu>Settings> and use the backup assistant for your contacts so you don't have to key them in individually.
    Hope this fixes the problem for you.  I'm on my third Razr in two months for various issues.

  • Want to switch the position for the Fn key and Ctrl key~~ very annoying

    I got my W520 CTO for about two weeks, I hate the keyboard design.
    I don't understand why Lenovo engineers change the positions of
    Fn key and Ctrl key! So unprofessional..
    For most keyboards, the Ctrl Key is at most bottom-left, which
    is convenient for the little finger.
    Ctrl key is so often used (especially for programmer) such that
    it should be easily pressed using litter finger.
    Fn key is seldom used (unless for projector, adjust brightness
    as such).
    I am thinking to change the position of the two keys, does Lenovo
    provide this service?

    http://forums.lenovo.com/t5/T400-T500-and-newer-T-series/Why-is-the-FN-key-on-the-outside-left-inste...
    I prefer Ctrl on the inside; it's closer to the pinky. Also more comfortable for FPS's as you can curl the pinky and hit it with the back rather than the front.
    W520: i7-2720QM, Q2000M at 1080/688/1376, 21GB RAM, 500GB + 750GB HDD, FHD screen
    X61T: L7500, 3GB RAM, 500GB HDD, XGA screen, Ultrabase
    Y3P: 5Y70, 8GB RAM, 256GB SSD, QHD+ screen

  • Diff b/w primary key and unique key?

    what is the diff b/w primary key and unique key?

    Hi,
    With respect to functionality both are same.
    But in ABAP we only have Primary key for the Database tables declared in the Data Dictionary.
    Unique is generally is the term used with declaring key's for internal tables.
    Both primary and Unique keys can identify one record of a table.
    Regards,
    Sesh

  • Difference between PRIMARY KEY and UNIQUE KEY with NOT NULL

    What is the difference between PRIMARY KEY and UNIQUE KEY with NOT NULL constraint?
    Message was edited by:
    Nilesh Hole

    Answer for the master!!!
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:8743855576462
    Thanks,
    Karthick

  • Difference between Unique key and Primary key(other than normal difference)

    Hello,
    1).Can any one tell me any other difference between Unique key and Primary key other than it having NULLs.
    2). What is the difference the words 'DISTINCT' and 'UNIQUE' in a sql query.
    Thanks in advance.

    Hi
    If you don't believe me than see the documentation in
    OTN.
    Ott Karesz
    http://www.trendo-kft.hu
    SQL> create table scott.tbl_clob
      2  (sss CLOB)
      3  /
    Tabelle wurde angelegt.
    SQL> insert into scott.tbl_clob values('wrwrwrw')
      2  /
    1 Zeile wurde erstellt.
    SQL> insert into scott.tbl_clob values('wrwrwrw')
      2  /
    1 Zeile wurde erstellt.
    SQL> select distinct sss from scott.tbl_clob
      2  /
    select distinct sss from scott.tbl_clob
    FEHLER in Zeile 1:
    ORA-00932: nicht übereinstimmende Datentypen
    SQL> select unique sss from scott.tbl_clob
      2  /
    select unique sss from scott.tbl_clob
    FEHLER in Zeile 1:
    ORA-00932: nicht übereinstimmende Datentypen
    SQL> select distinct to_char(sss) from scott.tbl_clob
      2  /
    TO_CHAR(SSS)
    wrwrwrw
    SQL> select unique to_char(sss) from scott.tbl_clob
      2  /
    TO_CHAR(SSS)
    wrwrwrw
    SQL>

  • Arrow keys and enter key not functioning in Firefox 3.6 when viewing PDF

    I'm using Adobe Reader 9.3.0.
    I have a web application that displays PDFs (using Adobe Reader) in a browser.  The PDF is loaded onto the page inside an IFRAME.  In addition to the IFRAME containing a PDF, the page also includes several forms, text fields, etc. For the most part this is working fine.  However, I have a glitch when using this in Firefox 3.6. I'm finding that certain keyboard events are being lost and I strongly suspect that they are being swallowed by Adobe Reader.  When I place focus on an HTML text field and press enter key or arrow keys, I do not get the appropriate key events.  If I run the exact same test without the PDF IFRAME these key events work correctly, but as soon as I load the PDF into the IFRAME they do not.  I believe the primary key event that gets lost is the keydown event.  I do get the keyup event.
    Again, the events work correctly up until I load the PDF onto the page.
    I've verified that this error does not occur in Firefox 3.5 and 3.0.
    Here is a testcase to reproduce this:
    <html>
    <head>
        <title>JavaScript - Detecting keystrokes</title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
        <script type="text/javascript">
            var pdfURL = 'http://samplepdf.com/sample.pdf';
            window.onload = function () {
                init();
            document.defaultAction = true;
            function init() {
                var x = document.getElementById('testForm').getElementsByTagName('input');
                for (var i=0;i<x.length;i++) {
                    x[i].onclick = setEvents;
                    if (x[i].checked)
                        x[i].onclick();
                writeroot = document.getElementById('writeroot');
                document.getElementById('emptyWriteroot').onclick = function () {
                    writeroot.innerHTML = '';
                    return false;
            function setEvents() {
                if (this.id == 'default') {
                    document.defaultAction = !this.checked;
                    return;
                var eventHandler = (this.checked) ? detectEvent : empty;
                document.getElementById('textfield')['on'+this.id] = eventHandler;
                //document['on'+this.id] = eventHandler;
            function detectEvent(e) {
                var evt = e || window.event;
                writeData('<b>'+evt.type+'</b>:  keyCode=' + evt.keyCode+' : charCode=' + evt.charCode);
                return document.defaultAction;
            function empty() {
                // nothing
            var writeroot;
            function writeData(msg) {
                writeroot.innerHTML += msg + '<br />';
        </script>
        <style type="text/css">
            body {
                font-size: 12px;
            #writeroot {
                height: 300px;
                overflow: auto;
                border: 1px solid #2EB2DC;
        </style>
    </head>
    <body>
    <form id="testForm">
    <input type="checkbox" id="keydown" /> <label for="keydown">keydown</label><br />
    <input type="checkbox" id="keypress" /> <label for="keypress">keypress</label><br />
    <input type="checkbox" id="keyup" /> <label for="keyup">keyup</label><br />
    <input type="checkbox" id="default" /> <label for="default">Suppress default action</label><br />
    <input type="text" id="textfield" /><br />
    <button id="emptyWriteroot">Remove messages</button>
    </form>
    <a href="#" onclick="document.getElementById('docviewer-page').src=pdfURL;return false">Now load IFrame</a>
    <p id="writeroot"></p>
    <div id="container2" style="border:1px solid black;width:400px;height:200px">
            <iframe
                id='docviewer-page'
                name='docviewer-page'
                title='document page'
                src='http://www.google.com'
                align='left'
                width='100%'
                height='100%'
                scrolling='auto'
                frameborder=0></iframe>
    </div>
    </body>
    </html>
    Paste the above into an HTML document.  Open the HTML document in Firefox 3.6.  Check the four checkboxes.  Move into the text field and press arrow keys and enter key to observe the results when it is working correctly.  Then click on the "Now Load PDF" link.  Press the arrow keys and enter key again and observe that the behavior has changed.
    Anybody have any idea why this is happening or how to work around it?

    I found a workaround!
    By using an object tag instead of an iframe, all the keys seems to work fine and the PDF still renders in the page the same way.
    Here's a page that works:
    <html>
    <head>
        <title>JavaScript - Detecting keystrokes</title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
        <script type="text/javascript">
            var pdfURL = 'http://samplepdf.com/sample.pdf';
            window.onload = function () {
                init();
            document.defaultAction = true;
            function init() {
                var x = document.getElementById('testForm').getElementsByTagName('input');
                for (var i=0;i<x.length;i++) {
                    x[i].onclick = setEvents;
                    if (x[i].checked)
                        x[i].onclick();
                writeroot = document.getElementById('writeroot');
                document.getElementById('emptyWriteroot').onclick = function () {
                    writeroot.innerHTML = '';
                    return false;
            function setEvents() {
                if (this.id == 'default') {
                    document.defaultAction = !this.checked;
                    return;
                var eventHandler = (this.checked) ? detectEvent : empty;
                document.getElementById('textfield')['on'+this.id] = eventHandler;
                //document['on'+this.id] = eventHandler;
            function detectEvent(e) {
                var evt = e || window.event;
                writeData('<b>'+evt.type+'</b>:  keyCode=' + evt.keyCode+' : charCode=' + evt.charCode);
                return document.defaultAction;
            function empty() {
                // nothing
            var writeroot;
            function writeData(msg) {
                writeroot.innerHTML += msg + '<br />';
        </script>
        <style type="text/css">
            body {
                font-size: 12px;
            #writeroot {
                height: 300px;
                overflow: auto;
                border: 1px solid #2EB2DC;
        </style>
    </head>
    <body>
    <form id="testForm">
    <input type="checkbox" id="keydown" /> <label for="keydown">keydown</label><br />
    <input type="checkbox" id="keypress" /> <label for="keypress">keypress</label><br />
    <input type="checkbox" id="keyup" /> <label for="keyup">keyup</label><br />
    <input type="checkbox" id="default" /> <label for="default">Suppress default action</label><br />
    <input type="text" id="textfield" /><br />
    <button id="emptyWriteroot">Remove messages</button>
    </form>
    <a href="#" onclick="document.getElementById('docviewer-page').data=pdfURL;return false">Now load IFrame</a>
    <p id="writeroot"></p>
    <div id="container2" style="border:1px solid black;width:400px;height:200px">
            <object
                id='docviewer-page'
                name='docviewer-page'
                title='document page'
                data='http://www.google.com'
                align='left'
                width='100%'
                height='100%'
                ></object>
    </div>
    </body>
    </html>

  • Arrow Left key and arrow Up key and fn key not working properly !? Lenovo G580 PLEASE HELP x_x !

    Hi guys i have a Lenovo G580 im not sure which version but i can tell you its intel i.3  and its got usb3.0 on it and 500gb hdd. 2.20Ghz  4.00RAM.   
    been days that i try to solve my Fn Key problem and also the arrow left and arrow up keys < i was using Win8 and downgraded to Win7 last week and that problem has occured since ,it misbehaves and it only works for a short amount of time it randomly works those keys FN.arrow up/left keys randomly they work , i upgraded again to Win8.1 now for the first few boots evrything worked well fn key and arrow keys np.< and now again it stops working.. and btw. whenever i press hard against it it would work pressing down the fn and arrow left/up keys when i press really hard it works but then again it doesnt Soo end of the story its not functioning properly and i have Energy management and Display driver HD 3000 installed and i still got this problem .. is there any fix to this anyone please !? 

    Hey mate the keys are faulty nothing can fix it except for buying a new Replacement! , i fixed the problem simply by Replacing the KEYBOARD !  i went downtown and looked for a g580 keyboard and they didnt exactly have the same version g580 they had c or b580 i dont remmber what letter it was sorry ! but the thing is the whole keyboard layout of many Lenovo Laptops are the same just look one thats the same, cause mine wasnt for G580 but the thing is its still working perfectly ! only problem is the Screws didnt fit i had to cut out the sides of the screw hole thingies to make the keyboard fit in well in my G580 , Simply put all you need is a new keyboard replacement buy one they cost between 20-40$ worth it cause you wont have any faulty keys anymore evrything will work fine. no need to reinstall anything just replace it with new Keyboard. and Plus its easy to replace it by yourself. i replaced mine by myself easily. Problem fixed.

  • HP G62-348CA number keys and arrow keys not working

    Good day Experts! Can someone help me fix my laptop? I got G62-348CA unit. only number 5 and 6 in my number keys are working and also arrow keys down and right are not functioning. at first it was built with windows 7 home premium 64bit but then i have to reformat my laptop with windows 7 ultimate but i dont have available 64bit so i install 32bit of the OS. before i install the OS, number keys and arrow keys are working fine but after I reformat my laptop with ultimate 32bit, the said keys are not working. please guys help me. im having trouble with my unit and i dont know what to do. its pretty bad i dont have any idea. all the best with you guys and i'm hoping for your fast and kind response. thank you!

    Because the operating system does not affect the keyboard in that way . .. If the operating system has issues it would switch keys or assign wrong characters.
    I have replaced over 200 keyboards because of such issues

Maybe you are looking for

  • Why is the button sub-picture on all the time?

    I have been told to create a menu with just one button on it... PLAY. Don't ask me why. I think it is weird too... I insert the DVD in the player, menu appears, and, a fraction of a second later, the sub-picture comes on. Same thing happens in PREVIE

  • Installer for Weblogic Portal Sever

    Hi, am trying to install the Weblogic Portal server 10.3.2 from the following link. From => http://www.oracle.com/technology/software/products/wlp/index.html I downloaded the file that is for "Windows x86" as i am on Windows XP/SP3. 1)What do i need

  • How to reset frontendHTTPPort value via wlst?

    I have set the FrontendHTTPPort value as 80 (even though I didn't have any LBR setup)... now whenever I tried to access the /console via the regular port 7001 (host:7001/cosnole), it takes me to the host:80/console and fails. Since I can't login to t

  • Alert Configuration Transport

    Hi Everybody, I have configured alerts in Development system PI 7.0. Can we transport these Alerts to QA or we need to do re configuration for Alerts in different environments. Note : I am referrring to the configuration in ALRTCATDEF and Alert Confi

  • How do i uninstall "Easy Duplicate Finder"??  its in the trash but won't go away... i never ran the .dmg file, but trash says its in use!

    Hi .. i was trying to free up some space on my early 2009 mac mini, and i downloaded the Easy Duplicate Finder 3rd party thingy... i never ran the setup.dmg file and i tried to throw it away, but i can't empty it out of my trash because it says its i