Using decode for range of data

hi experts
i want to dicode distance which are between
1 to 50
51 to 100
101 to 150
i am using this query but it is giving some error
please tell me that how should solve this problem
select a.fr_wh,a.to_wh,nvl(a.distance,0) distance,
DECODE(a.distance,(select distance from evhdist_mst where distance between 0 and 50) , 25,
                              (select distance from evhdist_mst where distance between 0 and 100) , 50,                         
               100) cost,
b.rkpt_name "Source" , c.party_name "Destination"
from
evhdist_mst a,
evm_rkpt b,
evm_rkpt_wh d,
evm_party c
where
a.to_wh=c.party_cd
and a.fr_wh=d.wh_cd
and b.rkpt_cd=d.rkpt_cd
and (substr(a.TO_WH,1,6) = 'NPAM01')
AND b.rkpt_cd IN( 'NPAM0101','NPAM0102','NPAM0103')
and to_wh='NPAM01028'
thanks in advance
regards
manoj

This is your formatted code.
select a.fr_wh,
       a.to_wh,
       nvl(a.distance,0) distance,
       DECODE(a.distance,(select distance from evhdist_mst where distance between 0 and 50) , 25,
                         (select distance from evhdist_mst where distance between 0 and 100), 50, /*Should this be 0 to 100 or 51 to 100? */
              100) cost, /* In place of this, you need to have a CASE */
       b.rkpt_name "Source" ,
       c.party_name "Destination"
from evhdist_mst a,
     evm_rkpt b,
     evm_rkpt_wh d,
     evm_party c
where a.to_wh=c.party_cd
and a.fr_wh=d.wh_cd
and b.rkpt_cd=d.rkpt_cd
and (substr(a.TO_WH,1,6) = 'NPAM01')
AND b.rkpt_cd IN( 'NPAM0101','NPAM0102','NPAM0103')
and to_wh='NPAM01028'Like this
case when a.distance >= 0 and a.distance <= 50 then 25
     when a.distance >= 51 and a.distance <= 100 then 50
     else 100
end cost More over your scalar sub-query is not correct. It may result in more than one row and may fail during run-time.
Cheers
Sarma.

Similar Messages

  • Searching AW database for range of dates in AW 6.2.4

    I can no longer use my Microsoftworks 4 on eMac since doing a clean install of OS 10.4.11. Prior to that it worked fine in Classic mode. I copied Works folder from old Mac 6500 via home network using ethernet connection to router. Setup program became corrupted when copying from Mac 6500 to eMac, so now unable to use MSWorks. Database was pure simplicity for copying individual fields to next record, searching for range of dates, and matching records with partial string using "contains" function.
    Now using AW 6.2.4 which is more powerful but not as simple to use. Is it possible to do any of those tasks in AW? If so, how?

    1) copying data into a field in a record from the corresponding field in the preceding record
    Not automatic, but no more complicated than copying the information from the first record, then command-down and command-V; command-down and command-V; command-down and command-V; etc.
    2) matching records containing partial string
    If the partial string is expected in a particular field, use the "Match Records..." dialog from the Organize menu. Looking for records containing the word, "hoopla" in the field named "event", enter the following command: FIND("oop",'event',1)
    -- Note single quotes around the fieldname, and double quotes around text to be found. -- Search multiple fields by imbedding multiple FIND statements in an OR statement.

  • Interface Using BAPI for Uploading shipment datas

    Can any1 send me the example code for Inbound Interface using BAPI for Uploading shipment datas.please kindly send me the programs which u using with BAPI

    Hi
    Except hiring (or new joinee) for all other actions you can use below Function Module.
    HR_INFOTYPE_OPERATION.
    ~~~Ganesh Kumar K.

  • Why can't I use iCloud for exchange of data - like I could with MobileMe?

    Why can't I use iCloud for exchange of data - like I could with MobileMe?
    Oder auf Deutsch, warum kann ich keine Daten mehr in iCloud speichern bzw. zum Austausch bereitstellen, wie das bei MobileMe noch ging?
    Danke für die Hilfe
    Thanx in advance!

    The purpose of iCloud is to sync data between your devices.
    There is no "web address" to your files and no way to "share" them with others (except photos).

  • How to Use Decode for manipulating time

    How can i use Decode function to manipulate time...
    Example
    suppose ive employee and his time in...i want to display status field by using decode,which reflects if that employee came after 09:15:00 the status='L' else this will print 'P'
    i tried this
    SELECT pin_code,DECODE( to_char(ACCESS_TIME,'HH24:MI:SS'>'09:15:00','l','P'))STATUS
    FROM ATTENDANCE_REG
    this query hasn't work...
    waiting for reply
    Regards
    Danish Hayder

    SQL> select case when to_number(to_char(sysdate,'sssss')) > 33300 then 'L'
      2              else 'P' end status
      3  from dual;
    S
    L
    1 row selected.                                                                                                                                                                                                                                                                                                                                           

  • Using DECODE() to insert to DATE field

    I'm trying to use the DECODE function to test for NULL before inserting to a DATE field. However, it seems to only insert the DATE, with a "default" time of 12:00 - it isn't properly inserting the time.
    Basically I need to test if Date1 is NULL. If it isn't I need to concatenate the DATE from Date1 with the TIME from Date2 to get a full date/time... then insert this new value.
    Generic Example:
    CREATE TABLE DATETEST (TestID NUMBER(1), TestDate DATE);
    DECLARE
    v_Date1 DATE;
    v_Date2 DATE;
    BEGIN
    v_Date1 := TO_DATE('01-JAN-11 05:53:12', 'DD-MON-YY HH:MI:SS');
    v_Date2 := TO_DATE('08-FEB-11 02:18:31', 'DD-MON-YY HH:MI:SS');
    INSERT INTO DATETEST (TestID, TestDate) VALUES ('1', DECODE(v_Date1, NULL, NULL, TO_DATE(To_Char(v_Date1, 'DD-MON-YY') || ' ' || TO_CHAR(v_Date2, 'HH:MI:SS'),'DD-MON-YY HH:MI:SS')));
    INSERT INTO DATETEST (TestID, TestDate) VALUES ('2', TO_DATE(To_Char(v_Date1, 'DD-MON-YY') || ' ' || TO_CHAR(v_Date2, 'HH:MI:SS'),'DD-MON-YY HH:MI:SS'));
    END;
    SELECT TestID, TO_CHAR(TestDate, 'DD-MON-YY HH:MI:SS') from DATETEST;
    This example performs two inserts. One with the DECODE function, and one without. The one without inserts the time properly. Can anyone tell me why the one with the DECODE function doesn't? I realize I can use a simple if/then to check if the date is null above and put the date/time in a variable, but since my real scenario is in a large chunk of other stuff, I'm trying to keep it as streamlined as possible.
    Edited by: BoredBillJ on Jul 14, 2011 6:39 AM

    The problem you are having is due to the nature of how DECODE and CASE determine what datatype to return, and you nls_date_format settings. Both use the data type of the first returnable argument to determine all of them. So, in your decode statement, the first returnable value is NULL which, in the absence of a cast (either implicit or explicit), is a varchar2 column. So, if the date is not null, the implicit conversion to a varchar to match the retunr type, then back to date to insert into the table is losing the time. you need something more like:
       INSERT INTO test_date (Test_ID, TestDate)
       VALUES ('1', DECODE(v_Date1, NULL, TO_DATE(NULL),
                                          TO_DATE(To_Char(v_Date1, 'DD-MON-YY') || ' ' ||
                                          TO_CHAR(v_Date2, 'HH:MI:SS'),'DD-MON-YY HH:MI:SS')));Even if you use Solomon's method of generating the date, if you need the decode/case, then you will have to either use the TO_DATE(NULL) or use case instead of decode and reverse the test so the first returnable is a date like:
    SQL> DECLARE
      2     v_Date1 DATE;
      3     v_Date2 DATE;
      4  BEGIN
      5     v_Date1 := TO_DATE('01-JAN-11 05:53:12', 'DD-MON-YY HH:MI:SS');
      6     v_Date2 := TO_DATE('08-FEB-11 02:18:31', 'DD-MON-YY HH:MI:SS');
      7     INSERT INTO test_date (Test_ID, TestDate)
      8     VALUES ('1', CASE WHEN v_date1 IS NOT NULL
      9                       THEN TO_DATE(To_Char(v_Date1, 'DD-MON-YY') || ' ' ||
    10                                    TO_CHAR(v_Date2, 'HH:MI:SS'),'DD-MON-YY HH:MI:SS')
    11                       ELSE NULL END);
    12     INSERT INTO test_date (Test_ID, TestDate)
    13     VALUES ('2', TO_DATE(To_Char(v_Date1, 'DD-MON-YY') || ' ' ||
    14                  TO_CHAR(v_Date2, 'HH:MI:SS'),'DD-MON-YY HH:MI:SS'));
    15  END;
    16  /
    PL/SQL procedure successfully completed.
    SQL> select test_id, to_char(testdate, 'dd-mon-yyyy hh24:mi:ss')
      2  from test_date;
       TEST_ID TO_CHAR(TESTDATE,'DD
             1 01-jan-2011 02:18:31
             2 01-jan-2011 02:18:31John

  • Using DECODE Function to change data

    I am trying to use the Decode function in a SQL statement to find a field that has a specific type, and when it finds that type, I want to blank out the results in a different field.
    For example:
    DECODE(ADDR_TYPE,'HOME',PHONE='') HOME_PHONE

    something like:
    SQL> with t as
      2   (select 219 id,
      3           'BUS' addr_type,
      4           '505-555-5555' phone
      5      from dual
      6    union
      7    select 219 id,
      8           'HOME' addr_type,
      9           null   phone
    10      from dual
    11    union
    12    select 220 id,
    13           'BUS' addr_type,
    14           '101-111-1111'   phone
    15      from dual
    16    union
    17    select 220 id,
    18           'HOME' addr_type,
    19           null   phone
    20      from dual
    21    union
    22    select 223 id,
    23           'BUS' addr_type,
    24           '202-222-2222'   phone
    25      from dual
    26    union
    27    select 224 id,
    28           'HOME' addr_type,
    29           '303-333-3333'   phone
    30      from dual
    31    union
    32    select 225 id,
    33           'BUS' addr_type,
    34           null   phone
    35      from dual
    36    union
    37    select 226 id,
    38           'HOME' addr_type,
    39           null   phone
    40      from dual)
    41  select a.id,
    42         a.addr_type,
    43         decode(a.addr_type,'BUS',phone,null) phone
    44    from (select id, addr_type, phone,
    45                 row_number() over (partition by id order by id, decode(addr_type,'BUS',1,2)) rn
    46            from t) a
    47   where a.rn = 1;
            ID ADDR PHONE
           219 BUS  505-555-5555
           220 BUS  101-111-1111
           223 BUS  202-222-2222
           224 HOME
           225 BUS
           226 HOME
    6 rows selected.
    SQL>

  • How to use decode for this

    Hi All
    I have one table called agreementproductkey and some columns namely Agreementproductid, keytext, fliename etc.
    There is some condition if agreement product id in not null and keytext field and fileaname field is null then i need to display the value as "NO FILE"
    This what i tried
    select decode(keytext || ' | ' || filename,null,'No File',keytext || filename) display_value, id return_value
    from agreementproductkey
    where agreementproductid = 3173
    But i didnt get the NO FILE when key text field and filename field is null for this agreementproductid.
    Thanks & Regards
    Srikkanth.M

    Hi Srikkanth,
    In the decode part, you have concatenated keytext and filename using '|' due to which it will never evaluate to null, and hence 'NOFILE' will never be displayed. CASE is a better option instead of DECODE.
    SQL> CREATE TABLE t (agreementid NUMBER, keytext VARCHAR2(10), filename VARCHAR2(10));
    Table created
    SQL> INSERT INTO t VALUES (123, 'ABC', 'ABCFile');
    1 row inserted
    SQL> INSERT INTO t VALUES (123, NULL, 'XYZFile');
    1 row inserted
    SQL> INSERT INTO t VALUES (123, 'PQR', NULL);
    1 row inserted
    SQL> INSERT INTO t VALUES (123, NULL, NULL);
    1 row inserted
    SQL> SELECT agreementid, keytext, filename,
      2         DECODE(agreementid, NULL, 'AGREEMENT NULL', DECODE(keytext || filename, NULL, 'NO FILE', 'FILE PRESENT'))
      3    FROM t;
    AGREEMENTID KEYTEXT    FILENAME   DECODE(AGREEMENTID,NULL,'AGREE
            123 ABC        ABCFile    FILE PRESENT
            123            XYZFile    FILE PRESENT
            123 PQR                   FILE PRESENT
            123                       NO FILE
    SQL> Regards
    Ameya

  • How to use decode for a not = expression ?

    Hi ,
    i want to use in my seelct query decode( val1 , IF not = 'abc' , sum(val1)
    how can i express it as a not equal or even a >= in a decode ?
    kindly advise
    tks & rdgs

    hi ,
    i have used a function to resolve my issue
    tks for all the info
    rdgsYou would be better doing it all in SQL for performance reasons so you do not context switch between PL/SQL and SQL all the time...
    Ok, without using CASE...
    SQL> create table a (stupid_number_in_varchar  VARCHAR2(10));
    Table created.
    SQL> insert into a
      2  select '3' as stupid_number_in_varchar from dual union all
      3  select 'X' from dual union all
      4  select '4' from dual union all
      5  select 'X' from dual union all
      6  select '5' from dual;
    5 rows created.
    -- Strip out non numeric values...
    SQL> ed
    Wrote file afiedt.buf
      1  select decode(stupid_number_in_varchar, 'X', null, stupid_number_in_varchar) as mynum
      2* from a
    SQL> /
    MYNUM
    3
    4
    5
    -- Only take numbers >= 4 ...
    SQL> ed
    Wrote file afiedt.buf
      1  select decode(sign(mynum-4), -1, null, mynum)
      2  from (
      3       select decode(stupid_number_in_varchar, 'X', null, stupid_number_in_varchar) as mynum
      4       from a
      5*      )
    SQL> /
    DECODE(SIG
    4
    5
    -- Sum the result...
    SQL> ed
    Wrote file afiedt.buf
      1  select sum(mynum) from
      2  (
      3    select decode(sign(mynum-4), -1, null, mynum) mynum
      4    from (
      5         select decode(stupid_number_in_varchar, 'X', null, stupid_number_in_varchar) as mynum
      6         from a
      7         )
      8*   )
    SQL> /
    SUM(MYNUM)
             9
    SQL>

  • Using Highlight for columns in data tables

    Hi, I'm using the "Highlight" function of SpryEffects in
    combination with the sorting features. My HTML structure is a
    simple data table, with a repeating region on the table row, so it
    pulls in as many rows there are pieces in the attached XML file.
    When I sort by one of the column headers at the top, I want to
    highlight that whole column, so users can see what they're sorting
    by. I'm able to get the first row of the data table highlighted,
    but none of the following rows work. I'm pretty sure the problem is
    that the highlight function only works when you use an id to define
    the element that you want highlighted. If it's in a repeating row,
    it sees many ids on the page, and only applies the highlight to the
    first one. I want to change the id to a class, so I can put
    multiple ones on the page and have it work, but I can't see how to
    do that in the SpryEffects.js file.
    Can anyone tell me if it's possible to do this? Thanks.
    Here's the portion of the .js file:
    function setupHighlight(element, effect)
    Spry.Effect.setStyleProp(element, 'background-image',
    'none');
    function finishHighlight(element, effect)
    Spry.Effect.setStyleProp(element, 'background-image',
    effect.options.restoreBackgroundImage);
    if (effect.direction == Spry.forwards)
    Spry.Effect.setStyleProp(element, 'background-color',
    effect.options.restoreColor);
    Spry.Effect.Highlight = function (element, options)
    var durationInMilliseconds = 1000;
    var toColor = "#ffffff";
    var doToggle = false;
    var kindOfTransition = Spry.sinusoidalTransition;
    var setupCallback = setupHighlight;
    var finishCallback = finishHighlight;
    var element = Spry.Effect.getElement(element);
    var fromColor = Spry.Effect.getStyleProp(element,
    "background-color");
    var restoreColor = fromColor;
    if (fromColor == "transparent") fromColor = "#ffff99";
    var optionFrom = options ? options.from : '#ffff00';
    var optionTo = options ? options.to : '#0000ff';
    if (options)
    if (options.duration != null) durationInMilliseconds =
    options.duration;
    if (options.from != null) fromColor = options.from;
    if (options.to != null) toColor = options.to;
    if (options.restoreColor) restoreColor =
    options.restoreColor;
    if (options.toggle != null) doToggle = options.toggle;
    if (options.transition != null) kindOfTransition =
    options.transition;
    if (options.setup != null) setupCallback = options.setup;
    if (options.finish != null) finishCallback = options.finish;
    var restoreBackgroundImage =
    Spry.Effect.getStyleProp(element, 'background-image');
    options = {duration: durationInMilliseconds, toggle:
    doToggle, transition: kindOfTransition, setup: setupCallback,
    finish: finishCallback, restoreColor: restoreColor,
    restoreBackgroundImage: restoreBackgroundImage, from: optionFrom,
    to: optionTo};
    var highlightEffect = new Spry.Effect.Color(element,
    fromColor, toColor, options);
    highlightEffect.name = 'Highlight';
    var registeredEffect =
    SpryRegistry.getRegisteredEffect(element, highlightEffect);
    registeredEffect.start();
    return registeredEffect;

    Hi Philip, Thanks a lot for puting this enhancement request through.
    Just downloaded the latest Patch upgrading to v 3.1.2-704 and confirmed that this functionality is not available yet.
    Keeping your experience in mind what kind of expectation to you have for the approval and realization of your request?
    Most likely this will take a couple of month – right? Or is there a beta version of 3.2 already available we could use.
    Thanks a lot. Cheers Stefan

  • Using cache for read only data

    In my application I have to display some read only data (in number of drop down present on several portlets)
    this data might be driven from the database or from some XML/property file.Not decided yet.
    for example : Country /state/City/Zip code etc..
    Kindly let me know how can I implement the same in Weblogic Portal 10.0.
    Do I have to use some third party caching mechanism like Hibernate cache for this
    or
    Weblogic portal do support caching ??
    Please suggest the all possible soultions to implement this.

    Cache cache = CacheFactory.getCache("yourCache"); //any name can be passed, and you can create as many as you want , perhaps by functionality, perhaps by size etc. If you want to configure statically you must use this name in the xml file. If you define it in the xml file , you can administer the cache from Portal Admin
    cache.put("key","value");
    cache.get("key");
    There are other advanced things you can do like Time To live / flushing / auto reload the cache which is all described in the javadoc
    regards
    deepak

  • Using workspaces for "ALMOST" static data

              Hi,
              The application that we are developing has the following requirement:
              We have a whole bunch of data that is ALMOST static as far as the application is concerned.
              However this data can change infrequently.
              We have two solutions in mind
              1) We are planning to have a StaticDataManager component that will handle the reading/updation of this data.
              All the other components of the application will get the static data from the StaticDataManager
              and cache this data to avoid communication between the components.
              The application will be hosted on a clustered WLS configuration.
              Now suppose an updation takes place, how best can we update all the components that have the cached data?
              2) In case we use Workspaces to cahce this static data, does the cluster configuration take care of
              updating the workspaces in the machines in the cluster?
              TIA!
              Sreeja
              

    If you do like you say and specify servera and then specify serverb
              respectively, then yes the workspace doesn't show the same information
              across the cluster. However, if you always specify the cluster, serverc,
              then no matter which side you update or read from the data is the same. So
              yes, if you specifiy a specific server in the cluster, and not the cluster,
              the data will not replicate across the cluster, and you lose concurrency.
              Let me paste in the output to show you what I am seeing which proves the
              data is being replicated with a single write.
              Tester ver. 1.00.00 ----> Test started...
              Connected successfully using http to ethouic97/198.171.100.107:80
              ws.store(DOG, FIDO)
              Connected successfully using http to ethouic97/198.171.100.106:80
              ws2.fetch(DOG)
              DOG = FIDO
              These are some system outs from the test app below with a few extra system
              outs. Notice if the cluster is always your connection point and not an
              individual server, in this case ethouic97. Then the answer to the original
              first question is YES, you can store near static data in workspaces on a
              cluster to have the data replicated across the cluster. However, you must
              always address the cluster and not the individual servers, in this case
              address ethouic97 never server 106 or 107 directly.
              Jonathon Cano
              "Mike Reiche" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Well, it does look like it works, doesn't it?
              >
              > Now try running the first half on one WLS instance and the other half of a
              different WL instance and
              > specify servera in the first half and serverb in the second half. If the
              workspace is replicated it should
              > work.
              >
              > It's broken now. Not really. Regardless of where the t3 connection is
              made, the workspace is
              > in the local WL instance.
              >
              > Mike
              >
              >
              > "Jonathon Cano" <[email protected]> wrote:
              > >Details:
              > >We are using a DNS cluster where serverc actually maps to servers a and
              b.
              > >If you set the workspace to SCOPE_SERVER, and use a t3client connection
              to
              > >the serverc, it can not be servera or serverb directly, then the
              workspace
              > >is updated or read from the data is persisted across both sides of the
              > >cluster. All reads and writes must be done using the cluster name for
              this
              > >to work. I use this to manage fail-over for some Vitria subscribers I
              have
              > >runnig at startup. I have a tester I wrote which works, here is the
              code:
              > >
              > > private void testWorkSpaces() {
              > >
              > > try {
              > >
              > > T3User userInfo = new T3User("system","password");
              > >
              > > T3Client t3 = new T3Client("http://cluster:80",userInfo);
              > > t3.connect();
              > >
              > > WorkspaceDef ws =
              >
              >t3.services.workspace().getWorkspace().getWorkspace("test",WorkspaceDef.OPE
              N
              > >,WorkspaceDef.SCOPE_SERVER);
              > > ws.store("DOG", "FIDO");
              > >
              > > t3.disconnect();
              > >
              > > T3Client t32 = new T3Client("http://cluster:80",userInfo);
              > > t32.connect();
              > >
              > > WorkspaceDef ws2 =
              >
              >t32.services.workspace().getWorkspace().getWorkspace("test",WorkspaceDef.OP
              E
              > >N,WorkspaceDef.SCOPE_SERVER);
              > > String dogName = (String) ws2.fetch("DOG");
              > >
              > >
              > > t32.disconnect();
              > >
              > > System.out.println(dogName);
              > >
              > > } catch (Exception e) {
              > > System.out.println("Test Work Spaces Failed.);
              > > e.printStackTrace();
              > > }
              > >
              > > }
              > >
              > >The first t3client connection echos out that it is connecting to servera.
              > >The second t3client connection echos out that it is connecting to
              serverb.
              > >However, the data being returned is the name FIDO which was written to
              the
              > >workspace when connected to servera. Thus, as long as you are connecting
              to
              > >the cluster, you get replication of data across cluster for workspaces.
              > >
              > >WLS 5.1
              > >
              > >Jonathon Cano
              > >
              > >
              > >"mreiche" <[email protected]> wrote in message
              > >news:[email protected]...
              > >>
              > >> >I am confused.
              > >>
              > >> Yes.
              > >>
              > >> >So why was the original answer to workspaces being used for clustering
              > >near static data NO?
              > >>
              > >> Because that's what the documentation says?
              > >>
              > >> Are you really, really sure it's being propagated? Or perhaps it's just
              > >being updated identically on both instances?
              > >>
              > >> Mike
              > >>
              > >> "Jonathon Cano" <[email protected]> wrote:
              > >> >I am confused. I am storing data in the workspaces right now, and I
              am
              > >> >using this data in a cluster. I can update the data in the cluster
              just
              > >> >fine, and both sides of the cluster are being updated. So why was the
              > >> >original answer to workspaces being used for clustering near static
              data
              > >NO?
              > >> >
              > >> >Jonathon Cano
              > >> >
              > >> >"Tao Zhang" <[email protected]> wrote in message
              > >> >news:[email protected]...
              > >> >>
              > >> >> But the problem is whether you want Exactly-once-per-cluster data or
              > >not.
              > >> >> If not, you can deploy the data object into each server in the
              cluster,
              > >> >but in the data object, it contains the logic of updating itself.
              > >> >> Otherwise, you have to make it a pinned service.
              > >> >>
              > >> >> It's hard to describe here.
              > >> >>
              > >> >> Hope the document can solve your problem.
              > >> >>
              > >> >> http://www.weblogic.com/docs51/classdocs/API_jndi.html#user
              > >> >>
              > >> >> Good Luck.
              > >> >>
              > >> >> Tao Zhang
              > >> >>
              > >> >> "Sreeja" <[email protected]> wrote:
              > >> >> >
              > >> >> >Thanks. Can you please elaborate on the solutions 1 and 2. We are
              > >trying
              > >> >to eliminate the
              > >> >> > usage of 3 - entity beans - since we do not want the components
              using
              > >> >the data to contact
              > >> >> >the entity bean every time they need the static data - as this
              would
              > >> >result in remote calls
              > >> >> >for every usage.
              > >> >> >Sreeja
              > >> >> >
              > >> >> >"Tao Zhang" <[email protected]> wrote:
              > >> >> >>No, the workspace can't be clustered, the data can't be propagated
              to
              > >> >other
              > >> >> >>servers in the cluster.
              > >> >> >>Of course , you can select one server as the data holder and other
              > >> >servers
              > >> >> >>will be t3 client. But it's time consuming to
              > >> >> >>connect to the data holder server.
              > >> >> >>Possible solutions:
              > >> >> >>1. RMI.
              > >> >> >>Deploy the rmi as pinned service which hold the data.
              > >> >> >>2. jndi
              > >> >> >>The data can be propagated by jndi's default behavior.
              > >> >> >>3. database or entity bean.
              > >> >> >>
              > >> >> >>Hope this can help.
              > >> >> >>
              > >> >> >>Tao Zhang
              > >> >> >>
              > >> >> >>Sreeja <[email protected]> wrote in message
              > >> >> >>news:[email protected]...
              > >> >> >>>
              > >> >> >>> Hi,
              > >> >> >>>
              > >> >> >>> The application that we are developing has the following
              > >requirement:
              > >> >> >>> We have a whole bunch of data that is ALMOST static as far as
              the
              > >> >> >>application is concerned.
              > >> >> >>> However this data can change infrequently.
              > >> >> >>> We have two solutions in mind
              > >> >> >>> 1) We are planning to have a StaticDataManager component that
              will
              > >> >handle
              > >> >> >>the reading/updation of this data.
              > >> >> >>> All the other components of the application will get the static
              > >data
              > >> >from
              > >> >> >>the StaticDataManager
              > >> >> >>> and cache this data to avoid communication between the
              components.
              > >> >> >>> The application will be hosted on a clustered WLS configuration.
              > >> >> >>> Now suppose an updation takes place, how best can we update all
              the
              > >> >> >>components that have the cached data?
              > >> >> >>>
              > >> >> >>> 2) In case we use Workspaces to cahce this static data, does the
              > >> >cluster
              > >> >> >>configuration take care of
              > >> >> >>> updating the workspaces in the machines in the cluster?
              > >> >> >>>
              > >> >> >>> TIA!
              > >> >> >>> Sreeja
              > >> >> >>>
              > >> >> >>
              > >> >> >>
              > >> >> >
              > >> >>
              > >> >
              > >> >
              > >>
              > >
              > >
              >
              

  • Oracle giving Block corruption errors when using CDC for sending the data to SQL Server 2012

    Hello Friends,
    We are facing an error while using CDC with Oracle. It is a "Block corruption" error, which indicates at some level of data corruption. We ran RMAN validate command to scan the database for corruption but it returned with no errors, however he
    Alert Log in Oracle is still coming up with the following error. Has anyone experienced this error when using Oracle Standard Edition and SQL 2012 ?
    Trace file e:\app\pulse-ad\diag\rdbms\orcl\orcl\trace\orcl_ora_5992.trc
    Oracle Database 11g Release 11.1.0.7.0 - 64bit Production
    Windows Server 2003 Version V5.2 Service Pack 2
    CPU                 : 4 - type 8664, 4 Physical Cores
    Process Affinity    : 0x0000000000000000
    Memory (Avail/Total): Ph:6782M/24575M, Ph+PgF:12203M/30844M
    Instance name: orcl
    Redo thread mounted by this instance: 1
    Oracle process number: 151
    Windows thread id: 5992, image: ORACLE.EXE (SHAD)
    *** 2013-12-12 03:04:33.655
    *** SESSION ID:(1281.3832) 2013-12-12 03:04:33.655
    *** CLIENT ID:() 2013-12-12 03:04:33.655
    *** SERVICE NAME:(orcl) 2013-12-12 03:04:33.655
    *** MODULE NAME:(xdbcdcsvc.exe) 2013-12-12 03:04:33.655
    *** ACTION NAME:() 2013-12-12 03:04:33.655
    Lost-write detected for sequence 70856. The lost-write starts occurring in block 11193. The current block being validating is 12930.
    Block dump of the first lost-write block:
    Flag: 0x1 Format: 0x22 Block: 0x00002bb9 Seq: 0x000114bf Beg: 0x94 Cks:0x68ee
    Dump of memory from 0x0000000598D06C00 to 0x0000000598D06E00
    598D06C00 00002201 00002BB9 000114BF 68EE8094  [."...+.........h]
    598D06C10 00085BF1 0023BDA1 000DE19C 000DE19C  [.[....#.........]
    598D06C20 0000000C 00000000 2209160A 5BF10000  [..........."...[]
    598D06C30 3EB10502 00C0F5CA 0031BDA1 00010205  [...>......1.....]
    598D06C40 02B22C6A 038A6D69 00000001 00000000  [j,..im..........]
    598D06C50 4D554407 30373230 35BB0206 001100AE  [.DUM0270...5....]
    598D06C60 0001040A 000D000E 038A6D69 56B25735  [........im..5W.V]
    598D06C70 729C0003 E19C0001 000C0006 000D0006  [...r............]
    598D06C80 02BB0502 00C0F5CD 0023BDA1 000A0002  [..........#.....]
    598D06C90 00C00013 000000D0 00030201 56B25736  [............6W.V]
    598D06CA0 03890001 00000000 00000000 002E0105  [................]
    598D06CB0 FFFF0003 00C0F5CD 56B25736 3EB10003  [........6W.V...>]
    598D06CC0 FFFF0024 0014000C 000C0018 00120014  [$...............]
    598D06CD0 09CC0058 E75B0022 0009000F 00085BF1  [X...".[......[..]
    598D06CE0 0024BDA1 000DE19D 000DE19D 0000000C  [..$.............]
    598D06CF0 00000000 2309160A 5BF10000 3EB10502  [.......#...[...>]
    598D06D00 00C0F5CD 0020BDA1 00010205 02B22C72  [...... .....r,..]
    598D06D10 03900974 00000019 00000000 3030300A  [t............000]
    598D06D20 33303030 06323132 AE35BB02 0B441100  [0003212...5...D.]
    598D06D30 0001040A 000D000E 03900974 56B25736  [........t...6W.V]
    598D06D40 729C0003 E19D0011 000C0006 000D0006  [...r............]
    598D06D50 02BB0502 00C0F5CD 0024BDA1 00EA0002  [..........$.....]
    598D06D60 00270016 000001FC 00032C01 56B25736  [..'......,..6W.V]
    598D06D70 00000001 00000000 30393007 002E0105  [.........090....]
    598D06D80 FFFF0003 00C0F5CD 56B25736 00000003  [........6W.V....]
    598D06D90 FFFF0025 00140052 000C0018 00070035  [%...R.......5...]
    598D06DA0 0003000A 00070003 0001001D 00030001  [................]
    598D06DB0 00010001 00010001 00010001 00010001  [................]
    598D06DC0 00010001 00010001 00010001 00010001  [................]
    598D06DD0 00010001 00000001 00010001 00010001  [................]
    598D06DE0 00010001 00000014 09720174 00000022  [........t.r."...]
    598D06DF0 0009000F 00085BF1 0025BDA1 000DE19A  [.....[....%.....]
    Block dump of the current block being validating:
    Flag: 0x1 Format: 0x22 Block: 0x00003282 Seq: 0x000114c8 Beg: 0x0 Cks:0x312a
    Dump of memory from 0x0000000598DDFE00 to 0x0000000598DE0000
    598DDFE00 00002201 00003282 000114C8 312A8000  [."...2........*1]
    598DDFE10 50424703 31303607 34353335 69745319  [.GBP.6015354.Sti]
    598DDFE20 6E696C72 72502067 6375646F 4C207374  [rling Products L]
    598DDFE30 4E206474 C3025650 0380013D 0457454E  [td NPV..=...NEW.]
    598DDFE40 4E1E09C2 1E09C204 10C2024E 1E09C204  [...N....N.......]
    598DDFE50 09C2044E C2024E1E 03C30510 021B0929  [N....N......)...]
    598DDFE60 C3053DC3 0F192602 2602C305 C3050F19  [.=...&.....&....]
    598DDFE70 0C1A6203 5102C105 C2041F4E 044E1E09  [.b.....QN.....N.]
    598DDFE80 4E1E09C2 0410C202 4E1E09C2 1E09C204  [...N.......N....]
    598DDFE90 10C2024E 2903C305 78071B09 011D0B71  [N......)...xq...]
    598DDFEA0 BF020101 1FBF0215 4E018001 53014E01  [...........N.N.S]
    598DDFEB0 0723002C 0B0C7178 0A3C3C18 30303030  [,.#.xq...<<.0000]
    598DDFEC0 33373030 4D033337 47034255 36075042  [007373.MUB.GBP.6]
    598DDFED0 38333936 4E113331 2065776B 74616C50  [693813.Nkwe Plat]
    598DDFEE0 6D756E69 56504E20 0B0AC303 4E038001  [inum NPV.......N]
    598DDFEF0 C2045745 0459512E 59512EC2 5253C203  [EW...QY...QY..SR]
    598DDFF00 512EC204 2EC20459 C2035951 C3055253  [...QY...QY..SR..]
    598DDFF10 1B092903 0B0AC303 3C04C305 C3053239  [.).........<92..]
    598DDFF20 32393C04 4F08C305 C105114F 1F4E5102  [.<92...OO....QN.]
    598DDFF30 512EC204 2EC20459 C2035951 C2045253  [...QY...QY..SR..]
    598DDFF40 0459512E 59512EC2 5253C203 2903C305  [.QY...QY..SR...)]
    598DDFF50 78071B09 01190A71 C0030101 C0034709  [...xq........G..]
    598DDFF60 8001330A 4E014E01 002C5301 71780723  [.3...N.N.S,.#.xq]
    598DDFF70 3C180B0C 30300A3C 30303030 33373337  [...<<.0000007373]
    598DDFF80 42554D03 50424703 31304207 344C5131  [.MUB.GBP.B011QL4]
    598DDFF90 6F725020 63657073 614A2074 206E6170  [ Prospect Japan ]
    598DDFFA0 646E7546 64724F20 44535520 30302E30  [Fund Ord USD0.00]
    598DDFFB0 04C30331 03800133 0557454E 5B1603C3  [1...3...NEW....[]
    598DDFFC0 03C30521 04215B16 1F4004C3 1603C305  [!....[!...@.....]
    598DDFFD0 C305215B 215B1603 4004C304 03C3051F  [[!....[!...@....]
    598DDFFE0 031B0929 043304C3 4D245AC2 245AC204  [).....3..Z$M..Z$]
    598DDFFF0 02C3054D 040A1A18 494002C1 1603C305  [M.........@I....]
    *** 2013-12-12 03:05:07.984
    ** LOGMINER WARNING - Invalidated 6 LCRs **
    Complete dump of first invalid START LCR follows:
    ++  LCR Dump Begin: 0x0000000532C004E0 - CANNOT_SUPPORT
         op: 255, Original op: 3, baseobjn: 0, objn: 233316, objv: 1
         DF: 0x00000002, DF2: 0x00000000, MF: 0x00000000, MF2: 0x00000000
         PF: 0x40000001, PF2: 0x00002000
         MergeFlag: 0x00, FilterFlag: 0x00
         Id: 0, iotPrimaryKeyCount: 3, numChgRec: 4
         NumCrSpilled: 0
         RedoThread#: 1, rba: 0x0114c8.0001c6ce.00d4
         scn: 0x0003.56b593be, xid: 0x0008.00c.00100d85, pxid: 0x0008.00c.00100d85
         ncol: 0newcount: 0, oldcount: 0
         LUBA: 0x3.c109c0.c.15.38f64
    Thanks
    Dee

    Hi Dee,
    Thank you for your question.
    I am trying to involve someone more familiar with this topic for a further look at this issue. Sometime delay might be expected from the job transferring. Your patience is greatly appreciated.
    Thank you for your understanding and support.
    Regards,
    Mike Yin
    TechNet Community Support

  • Create new LSMW using Idoc for HR master Data

    Hi Guys,
    I was wondering id someone could help me. I have started developing an LSMW, of which I have already
    created the Object. I have also created the Maintain attributes and I have supplied the Message Type, Basic Type and activated the IDOC inbound processing after providing the appropriate information.
    The question I have is in the "Maintain source structure" do I need to create a structure for data records
    and a structure for header?
    Can I do a recording for transaction     -
    "PA30" --->  update infotype 6
                                                           |
    IDOC   -
    > infotype 0,1,2,6
    I have previously created HR LSMW using recording, but I have not used the IDOC facility and I'm not
    sure of the differences.
    Does anyone have any documentation.
    Regards,
    Frank

    Dear Frank,
    For Idoc method need to do setting first.
    Creating  pratner profile,.....................etc.
    then rest of the thing are same.
    Best Regards,
    Flavya

  • Report Runing Very Slow for  range even data set for that range is small

    Hello Experts,
      I have a report which runs on date selection.
    When I run the report for say 01.01.2000 -31.12.2010  whcih contains 95% of the data , the report output is coming with in a minute.
    But when I ran the report from 01.01.2011 - 31.12.2011 , or say 01.01.2011 for a single day , where the data set is hardly 3k records,the report is runing for long time 15 - 20 minutes and not showing output.
    But when i remove this variable and run the report , it is coming again with in a minute.
    One weird thing is when i ran the report from 01.01.2000 - 31.12.2011 it is also coming with in a minute, but when i ran for 01.01.2011 single day it is not coming.
    Can any one share some inputs on this one.
    Thanks
    Vamsi

    Hello Experts,
      I have a report which runs on date selection.
    When I run the report for say 01.01.2000 -31.12.2010  whcih contains 95% of the data , the report output is coming with in a minute.
    But when I ran the report from 01.01.2011 - 31.12.2011 , or say 01.01.2011 for a single day , where the data set is hardly 3k records,the report is runing for long time 15 - 20 minutes and not showing output.
    But when i remove this variable and run the report , it is coming again with in a minute.
    One weird thing is when i ran the report from 01.01.2000 - 31.12.2011 it is also coming with in a minute, but when i ran for 01.01.2011 single day it is not coming.
    Can any one share some inputs on this one.
    Thanks
    Vamsi

Maybe you are looking for

  • AutomationException while calling a method

    Hi all, I've got a problem accessing a COM/DCOM component in a Win2k box (Advanced Server) with jcom. I configured the server and client described in the "JSP to COM" example. The only difference: I don't want to access the excel sheet and I don't us

  • VPN not working after upgrading to Mavericks

    After upgrading to OS X 10.9 Mavericks - VPN not working. I am able to connect to VPN server fron inside local network, but can't do the same from outside through the router (1. I have statis external IP 2. NAT port forwarding is OK 3. Other services

  • Free case issue - very limited info of cases :(

    Very limited info/spec/images are available for various cases for iPhone 4. It is pathetic that companies don't bother to publish more info when they are reaping millions by selling their cases. It wouldn't take more than an hour to publish more info

  • Is there a way to import ONLY videos into PE8, not photos?

    I have a million photos I never intend to use in a Premiere Elements 8 production. Using the PE8 "Organizer," is there a way to import ONLY videos into PE8, not photos?

  • Differences between Beta R2 and Beta R3 JDev connecting to Beta R2 BPEL PM?

    I have a Beta R2 BPEL PM runing on a Linux server using an Oracle 10g DB as the dehydration store. All has been fine using the Windows based Beta R2 JDev for development and deployment. So... now I have downloaded the Beta R3 JDev for windows and try