Compares single value content property to single value property

Hi,
I am using WLPS 3.2 with weblogic apps 5.1.
This is when regarding content selection rules. When u go into the rules
management and try to create a content selection rule : Then display content
based on:
we see 3 templates to choose from. Now if u look at template 2 it says
:Value with Property Example
This template compares a single-value content property to another
single-value property. content.investor_type equals user.investor_type
It says this template compares "single value" content property to another
"single-value property". What i did was set up a rule that comared a single
value content property to a "multiple" value user property (i.e. the user
property was allowed to have multiple values-check boxes). The rule was set
up fine. When i ran the rule with the <pz:contentselector> tag it dint
return the desired content object. Now if i set up the same rule to match a
single valued user property then it worked!!! Could you please let me know
why this happens and is this a limitation of the tool. What is an
alternative solution for me to compare a content property to a multi valued
user property.
Thanks,
--Kapil

Hi Kapil,
You're correct on all counts. This workaround does move the content
selection into the JSP, rather than using a rule -- which is not ideal.
Also, your suggestion to build one query string to cut down on the number of
database calls is a good improvement.
- Ginny
"kapil khanna" <[email protected]> wrote in message
news:[email protected]...
Hi Ginny,
I really appreciate ur response. This work around was not knew to me. Iwas
expecting a better work around from some reasons:
i) The definition of this rule is hard coded and not administered thu the
tools interface.
ii) There are multiple database calls for each property value retrieved
every time the <cm:select> tag is executed which is very expensive.
iii) The query that i build for the <cm:select> or <pz:contentQuery> tag
doesnt support the in statement.
My work around was something like this:
Build the query string first which would look something like this
CONTENT.interest like '*Science*' || CONTENT.interest like '*Astronomy*'
Then run the <cm:select> or <pz:contentQuery> tag so that i have only one
database call.
Considering the user has 2 interests chosen Science and astronomy. I usethe
like so that CONTENT can be tagged to accomodate multiple values which is
very possible in a real life situation. For eg: <meta name="interest"
content="Science,Astronomy" >
Is this a better work around or am i totally out of line.
Thanks for your help and time
--Kapil
"Ginny Peterson" <[email protected]> wrote in message
news:[email protected]...
Hi Kapil,
Yes -- this is a limitation with the phrase templates. The "Value with
Property" phrase template compares a single-value content property to
another single-value property. What's key here (and often overlooked)
is
that fact that the property you're using must be a single-valueproperty.
>>
There is a workaround using the <cm:select> tag rather than the <pz>tags.
Basically, it involves getting a list of the values for yourmultiple-value
property, and iterating over that list, selecting the content for each
of
the items in the list.
Here's some sample code. Assume you have a text, multiple, unrestricted
property called "MyInterests" in property set "TestPropertySet"; a user
might have values like this: "Science, Astronomy, Cooking".
<%@ page extends="com.beasys.commerce.axiom.p13n.jsp.P13NJspBase"%>
<%@ page import="com.beasys.commerce.content.ContentHelper"%>
<%@ taglib uri="es.tld" prefix="es" %>
<%@ taglib uri="cm.tld" prefix="cm" %>
<%@ taglib uri="um.tld" prefix="um" %>
<!-- Get the user and group names -->
<%
String userName = (String)getSessionValue(SERVICEMANAGER_USER,request);
String groupName = (String)getSessionValue(SERVICEMANAGER_SUCCESSOR,
request);
%>
<!-- Get the profile for the user -->
<%
// Check to see if logged in, then getProfile for the user with groupas
successor
if(getLoggedIn(request))
%>
<um:getProfile scope="session" profileKey="<%= userName %>"
successorKey="<%= groupName %>" />
<%
else // use the default profile for the group
%>
<um:getProfile scope="session" profileKey="<%= groupName %>"
groupOnly="true" />
<%
%>
<!-- Get the property value for the user -->
<um:getProperty id="areas" propertySet="TestPropertySet"
propertyName="MyInterests" />
<br><br>Interests for <%= userName %>:
<%
// Multi-valued properties are retrieved as an ArrayList, so cast to a
Collection so we can iterate through
Collection c = (Collection)areas;
String queryString;
Iterator i = c.iterator();
while(i.hasNext())
String nextVal = (String)i.next();
queryString = "CONTENT.interests == '" + nextVal + "'";
%>
<cm:select contentHome="<%= ContentHelper.DEF_CONTENT_MANAGER_HOME %>"
query="<%= queryString %>" id="docList"/>
<es:forEachInArray id="aDoc" array="<%= docList %>"
type="com.beasys.commerce.axiom.content.Content">
<li>Matched document message:
<cm:printProperty id="aDoc" name="message" encode="html"/>
</es:forEachInArray>
<%
%>
FYI, this limitation is not present in WLCS 3.5; it's much more flexiblein
terms of using mutli-valued properties (and multi-valued meta tags) in
rules.
I hope this helps!
- Ginny
"kapil khanna" <[email protected]> wrote in message
news:[email protected]...
Hi,
I am using WLPS 3.2 with weblogic apps 5.1.
This is when regarding content selection rules. When u go into the
rules
management and try to create a content selection rule : Then displaycontent
based on:
we see 3 templates to choose from. Now if u look at template 2 it says
:Value with Property Example
This template compares a single-value content property to
another
single-value property. content.investor_type equalsuser.investor_type
It says this template compares "single value" content property toanother
"single-value property". What i did was set up a rule that comared asingle
value content property to a "multiple" value user property (i.e. the
user
property was allowed to have multiple values-check boxes). The rule
was
set
up fine. When i ran the rule with the <pz:contentselector> tag it dint
return the desired content object. Now if i set up the same rule to
match
a
single valued user property then it worked!!! Could you please let me
know
why this happens and is this a limitation of the tool. What is an
alternative solution for me to compare a content property to a multivalued
user property.
Thanks,
--Kapil

Similar Messages

  • How to compare single value with multiple values

    In my query I have something like this:
    A.SOR_CD=B.SOR_CODE where A and B are 2 different tables. This condition is in the where clause. The column in table A has single values but some values in table B have multiple comma separated values (822, 869, 811, ..).  I want to match this single
    value on the left side with each of the comma separated values. Please let me know how will I be able to do it. The number of comma separated values on the right side may vary.

    Hi MadRad123,
    According to your description, you want to compare single value with multiple values in your query. Right?
    In this scenario, the table B has comma separated values, however those comma separated values are concatenated into a string. So we can use charindex() function to return the index of the table A value. And use this index as condition in
    your where clause. See the sample below:
    CREATE TABLE #temp1(
    ID nvarchar(50),
    Name nvarchar(50))
    INSERT INTO #temp1 VALUES
    ('1','A'),
    ('2','A'),
    ('3','A'),
    ('4','A'),
    ('5','A')
    CREATE TABLE #temp2(
    ID nvarchar(50),
    Name nvarchar(50))
    INSERT INTO #temp2 VALUES
    ('1','a,A'),
    ('2','A,B'),
    ('3','c'),
    ('4','A,C'),
    ('5','d')
    select * from #temp1 a inner join #temp2 b on a.ID=b.ID
    where CHARINDEX(a.Name,b.Name)>0
    The result looks like below:
    Reference:
    CHARINDEX (Transact-SQL)
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

  • How can I compare single value with multiple value...

    Hello,
    I want to compare one value with multiple values, how can it possible ?
    Here in attachment I tried to design same logic but I got problem that when I entered value in y that is compared with only minimum value of x, I don't want that I want to compare y value with all the x value and then if y is less then x while loop should be stop.
    I want to do so because in my program some time I didn't get result what I want, for example x values is 4,5,6,7,8  and y value is  suppose 6 then while loop should be stop but here it consider only minimum number and its 4 here so while loop is not stop even y is less then 7 and 8. So I want to compare y value with all the entered values of x and if y is less then any of x values then while loop should be stop and led should be ON.
    Please guide me how can I do so.....
    Solved!
    Go to Solution.
    Attachments:
    COMPARISON.vi ‏8 KB

    AnkitRamani wrote:
    Thank you very mach for your help..
    may be i have solved this ....i have made one change in my vi that instead of min. i select max and max. value is compare with the value of y and then if y is less then the max. while loop will be stop other wise its run continuously.
    this is working fine...
    any ways thanks again for your help and time...
    I have to agree with Lewis - his way is more efficient.
    Bill
    (Mid-Level minion.)
    My support system ensures that I don't look totally incompetent.
    Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.

  • Help comparing the value of a button using the Property Node (I get a variant)

    Dear Sirs:
    (I'm using LabView 6. I guess the solution is different for 6.1)
    Currently I have created an array of Boolean RefNums (which point to many, many buttons). When I need to know when any (and which) of the buttons was pressed I just compare every element on the array with the constant TRUE. It fact, as the array is built from RefNums, I should compare the VALUE from the Property Node.
    The problem here is that the Property Node for this type of Boolean is a LV Variant, and I need to compare this with a TRUE/FALSE value.
    I tried to convert the TRUE constant to a LV variant and visc. But nothing works... I always get that none of the buttons was pressed.
    Here it co
    mes the question: "How can I compare the value of a Property Node for a Boolean (Button) with a TRUE (or False) constant?"
    BTW, maybe I should explain why I'm using RefNums instead of the direct values: As my project requires tons of buttons, I would preffer using RefNums to refer to them. (I.E. I could use a single VI that takes the RefNum and formats the button to hide it for certain users).
    I have enclosed a VI that contains what I've achieved until now, which is nothing
    I appreciate your time and help.
    Best regards,
    JAVIER VIDAL
    Attachments:
    Other_Main_Menu.vi ‏103 KB

    Javier,
    There is another problem in your code: the booleans are not polled by the main loop so they will remain false until the user presses them again. This renders the boolean latch action useless.
    What you can do is to change the mechanical action of the booleans to non-latch. When you detect a "true" in the polling loop, set the boolean to false again. One added benefit is that once all boolean are non-latch, the value property won't be a variant but a boolean so conversion is no longer needed.
    LabVIEW, C'est LabVIEW

  • Comparing Hexadecimal value in program

    Hi friends,
    I have requirement in this I have to pick a file and have to write some logic by comparing file contents.
    File contents some hexadecimal character like '#'.
    When I am writing simple if condition like
    if var = '#'.
    endif.
    It is not going in that if condition even when the var has value from # from file. so i think as it is hexadecimal value there is some other way to compare it.
    Please let me know how can I compare hexadecimal value.

    Indeed # is a character representation of a separator (tab or space) which is seen as # in character mode.
    Use below snippet to compare it
    DATA: xsep TYPE xstring,
                    sep TYPE string.
                  xsep = '09'. "if separator is tab mark
                  xsep = '20'. "if it is space
              CALL FUNCTION 'HR_KR_XSTRING_TO_STRING'
                EXPORTING
                  in_xstring = xsep
                IMPORTING
                  out_string = sep.
             "now SEP contains character representation for separator (which is seen as #)
              "you can i.e. split uploaded file data (in iternal table) based on that separator
              SPLIT it_file_data AT sep INTO TABLE it_file_fields IN CHARACTER MODE.
              "for comparing use
              if var = sep.
              endif.
    Regards
    Marcin

  • Create a new column in a table that compares the value of one column with its previous value

    The DDL:
    DECLARE
    @T TABLE
    IDNO
    int,
    name
    varchar(40),
    [Date]
    datetime2,
    Price1
    float,
    Price2
    float
    DECLARE
    @K TABLE
    IDNO
    int,
    name
    varchar(40),
    [Date]
    datetime2,
    Price1
    float,
    Price2
    float
    INSERT
    INTO @T
    VALUES(22,'C_V_Harris','2014-01-02 10:23:49.0000000',
    23.335,      
    23.347)
    INSERT
    INTO @T
    VALUES(21,'C_V_Harris','2014-01-02 10:05:13.0000000',
    23.357,      
    23.369)
    INSERT
    INTO @T
    VALUES(20,'C_V_Harris','2014-01-02 09:56:15.0000000',
    23.364,      
    23.377)
    INSERT
    INTO @T
    VALUES(19,'C_V_Harris','2014-01-02 09:45:26.0000000',
    23.351,      
    23.367)
    INSERT
    INTO @T
    VALUES(18,'C_V_Harris','2014-01-02 09:43:20.0000000',
    23.380,      
    23.396)
    INSERT
    INTO @T
    VALUES(17,'C_V_Harris','2014-01-02 09:34:28.0000000',
    23.455,      
    23.468)
    INSERT
    INTO @T
    VALUES(16,'C_V_Harris','2014-01-02 09:30:37.0000000',
    23.474,      
    23.486)
    INSERT
    INTO @T
    VALUES(15,'C_V_Harris','2014-01-02 09:18:12.0000000',
    23.419,      
    23.431)
    INSERT
    INTO @T
    VALUES(14,'C_V_Harris','2014-01-02 09:16:06.0000000',
    23.360,      
    23.374)
    INSERT
    INTO @K
    SELECT
    ROW_NUMBER()
    OVER (ORDER
    by IDNO)
    AS RN,*
    FROM
    @T
    SELECT
    * FROM
    @K
    --not working:
    SELECT
    a.RN,a.Price2
    FROM
    @K a
    INNER
    JOIN @K
    b
    ON
    a.RN=b.RN-1
    WHERE
    a.Price2>b.Price2
    I need to create  a view with a column (say 'Comp' below) that compares the value of each row in Price2 with the previous Price2 row, and it is greater then +1, the
    same 0, and less -1.
    The processed table should be:
    IDNO
    name
    Date
    Price1
    Price2
    Comp
    22
    C_V_Harris
    1/2/2014 10:23:49
    23.335
    23.347
    0
    21
    C_V_Harris
    1/2/2014 10:05:13
    23.357
    23.369
    1
    20
    C_V_Harris
    1/2/2014 9:56:15
    23.364
    23.377
    1
    19
    C_V_Harris
    1/2/2014 9:45:26
    23.351
    23.367
    -1
    18
    C_V_Harris
    1/2/2014 9:43:20
    23.38
    23.396
    1
    17
    C_V_Harris
    1/2/2014 9:34:28
    23.455
    23.468
    1
    16
    C_V_Harris
    1/2/2014 9:30:37
    23.474
    23.486
    1
    15
    C_V_Harris
    1/2/2014 9:18:12
    23.419
    23.431
    -1
    14
    C_V_Harris
    1/2/2014 9:16:06
    23.36
    23.374
    -1
     How can I structure the statement to get (the most recent - order by date ) result for Comp?

    Satheesh Variath, I just had to make some corrections from your script to get the correct answer:
    CREATE
    VIEW vw_Comp
    AS
    SELECT
    TOP 1 t.IDNO,t.name,t.[Date],t.Price1,t.Price2,
    CASE
    WHEN t.Price2
    > LAG(Price2,1)
    OVER (PARTITION
    BY name
    ORDER BY IDNO) 
    THEN 1
    WHEN t.Price2
    < LAG(Price2,1)
    OVER (PARTITION
    BY name
    ORDER BY IDNo) 
    THEN -1
    ELSE 0
    END
    AS Comp
    FROM 
    @T t
    ORDER
    BY DATE
    DESC
    The adjustments: the selection of the most recent comparison (Top 1) and the use of the function LAG (instead of LEAD) to get the previous value of the column.

  • SSRS Expression to compare two values and get data from another dataset

    Hi,
    I have a requirement where in i need to compare a value of a dataset (not the one which table is poiting to)
    with the value of a text box, and return the count if it matches else 0, the expression is as below. Here 
    industryName and recCount are from the dataset ds_MedimOrLowImpactEntities.  whats wrong in this expression
    =Sum(IIF(Fields!industryName.Value = reportItems!hpapra_name.Value, Fields!RecCount.Value, 0), "ds_MediumOrLowImpactEntities")
    This is the error that i am getting:
    Any help on this is appreciated
    Kruthi Hegde

    Hi Kruthi,
    After testing the issue in my local environment, I can reproduce it. Just the error message said, “Aggregate function can be used only on report items contained in page headers and footers”. So the sum function that contains report items should be stayed
    at page headers or footers. Besides, you said the hpapra_name textbox contain a field from another dataset, not the ds_MedimOrLowImpactEntities dataset. While in Reporting Services, Report item expressions can only refer to other report items within the same
    grouping scope or a containing grouping scope. So consider the two issues, we should use some other expression to instead the “reportItems!hpapra_name.Value” expression.
    Take a look at the "Looking up values from another dataset" topic here:
    http://msdn.microsoft.com/en-us/library/ms159673.aspx#LookupFunctions
    Hope this helps.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • How  to compare previouse value in pl/sql array

    DECLARE
    CURSOR stg_raw_cur IS
    SELECT RAW_STG_ID,
    DEVICE_CD,
    MODEL_VERSION,
    PLATFORM_CD,
    PROFILE_COOKIE,
    LOCATION_CD,
    SAMPLE_RATE,
    EVENT_TYPE_CD,
    to_char(to_date(to_date(substr(EVENT_DATE_TIME,1,8),'yyyymmdd')-1 ||
    'T' ||
    substr(EVENT_DATE_TIME,10,8)
    || 'Z','DD-MON-RR"T"HH24:MI:SS"Z"'), 'YYYYMMDDYY"T"HH24:MI:SS"Z"' ) EVENT_DATE_TIME,
    EVENT_SPECIFIC,
    BATCH_ID,
    DWH_ARVL_DT,
    DWH_ARVL_DT_ID,
    DWH_CREATE_DT from dwh_stg.stg_raw where batch_id >= 200
    order by batch_id asc;
    TYPE stgrawarr IS TABLE OF stg_raw_cur%ROWTYPE;
    stg_raw_rec stgrawarr;
    l_batch_id NUMBER :=0 ;
    v_ctr NUMBER :=0;
    l_temp_batch_id number :=0;
    BEGIN
    OPEN stg_raw_cur;
    LOOP
    FETCH stg_raw_cur BULK COLLECT INTO stg_raw_rec LIMIT 100;
    EXIT
    WHEN stg_raw_cur%NOTFOUND;
    END LOOP;
    CLOSE stg_raw_cur;
    for i in stg_raw_rec.first..stg_raw_rec.last
    loop
    dbms_output.put_line('batch id is '|| stg_raw_rec(i).batch_id );
    IF l_batch_id != stg_raw_rec(i).batch_id
    then
    dbms_output.put_line('Different');
    end if;
    l_temp_batch_id := stg_raw_rec(i).batch_id;
    commit;
    end loop;
    END;
    I want to compare previous value of stg_raw_rec(i).batch_id if differnet then increament the value
    else leave the same.
    thanks.

    Try this,
    FOR i IN stg_raw_rec.FIRST .. stg_raw_rec.LAST
       LOOP
          IF l_temp_batch_id != stg_raw_rec (i).batch_id
          THEN
             --increment
             l_temp_batch_id := l_temp_batch_id + 1;
          END IF;
           DBMS_OUTPUT.PUT_LINE ('batch id is ' || stg_raw_rec (i).batch_id||' unique batch id is '||l_temp_batch_id);
        --  DBMS_OUTPUT.PUT_LINE ('batch id is ' || stg_raw_rec (i).batch_id);
        --  IF l_batch_id != stg_raw_rec (i).batch_id
        --  THEN
        --    DBMS_OUTPUT.PUT_LINE ('Different');
        --  END IF;
          l_temp_batch_id := stg_raw_rec (i).batch_id;
          COMMIT;
       END LOOP;

  • How to compare the values stored in the list

    Hi,
    I am having the requirement that i want to compare the values stored in the list.How to store the values in the list and compare the list values stored inside it.
    Regards,
    Ahamad

    http://java.sun.com/j2se/1.5.0/docs/api/java/util/Collections.html#sort(java.util.List)
    http://java.sun.com/j2se/1.5.0/docs/api/java/util/Collections.html#sort(java.util.List,%20java.util.Comparator)
    http://java.sun.com/j2se/1.5.0/docs/api/java/util/Comparator.html
    http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Comparable.html

  • Comparing two values in a jsp file.

    Hi every one.
    How can i compare to values ,one of them is picked up from a database and the second is passes to this page from html form as a parameter.
    e.g
    <c:when test="${param.password==user.password} ">
    i did it like that but it dosen't work .if i replaced one of them with an actual value like "123466" it work.is there some thing like String.equalsIgnoreCase() function
    to use it in such situations.
    thnx for any help.

    <c:when test="${param.password==user.password} ">instead try this..
    <c:when test="${param.password.equals(user.password)} ">

  • Function to compare particular value with LOV Additional Description column

    Hi,
    Is there an existing function that compares a value with the "Additional Description" of a particular LOV ?
    Can the comparison be done by "Adminstration - Personalization"?

    Sorry & thanks sathish,
    Now i got the result.
    SQL> select DECISIONED_STAGE_ID,DECISIONED_STAGE_USER_ID from naap10_application where APP_DECISION_DATE BETWEEN TO_DATE ('31.01.2007 00:00:00', 'DD.MM.YYYY HH24:MI:SS') AND TO_DATE ('31.01.2007 23:59:59', 'DD.MM.YYYY HH24:MI:SS')
    2 and application_id=2007010028552;
    DECISIONED_STAGE_ID DECISIONED_STAG
    2006060113 SYSTEM
    ================================
    But one doubt,
    When i created the column with the date datatype how it gets the time value,
    And in one environment db i got the result but in another environment i dont get,
    Shall i want to change any session status of date?

  • Aftereffects expression BUG. cannot compare the values of 2 sliders???????

    so do this:
    make a new comp with a new solid.
    add 2 slider effects to the layer.
    add an expression to the Opacity of the solid, add this tot he expression:
    // begin expression
    if(effect("slider_01")("Slider") == effect("slider_02")("Slider")){
    100
    }else{
    0
    // end expression
    then try setting the values of the sliders to be exactly the same. IF they are exactly the same, the solid should be visible.
    they NEVER evaluate as true. Which means this is a bug, no?

    hah!
    why is it like this?
    to compare the values of sliders, you can't just pick whip to it, like you are able to do for almost everything else.
    the trick is to pickwhip, get this: effect("slider_01")("Slider")
    then add    .value      to the end of it. because consistency is key.

  • Compare 2 value

    Hi All,
    I want to compare 2 values in same internal table.
    like.
    belnr     qty qty1
    1234    12   1
    1234    12   2
    I want to compare belnr value and put qty = 0 if belnr is duplicate.
    like
    belnr     qty qty1
    1234    12   1
    1234    00     2
    please help me.
    thanks in advance.

    HI
    i AM USING FOLLOWING CODE..
    ITAB , AND ITAB1 BOTH R INTERNAL TABLES
    AND I AM APPENDING THEM IN ONE..
    i AM GATING OUT PUT LIKE THIS:
    40559178            110.000           138.000  701002             202630
    40559178              4.000           138.000  701002             202630
    40559178             24.000           138.000  701002             202630
    I WANT OUTPUT LIKE :
    40559178            110.000           138.000  701002             202630
    40559178              4.000           000.000  701002             202630
    40559178             24.000           000.000  701002             202630
    FOR THIS OUTPUT I AM USING FOLLOWING CODE.
    DATA : CHECK TYPE C.
    LOOP AT ITAB.
    LOOP AT ITAB1 WHERE MBLNR_REG = ITAB-MBLNR_SRP .
      MOVE : ITAB-MBLNR_SRP TO ITAB3-MBLNR_SRP,
               ITAB-MATNR_SRP  TO ITAB3-MATNR_SRP,
               ITAB-MENGE_SRP TO ITAB3-MENGE_SRP,
               ITAB1-MENGE_REG TO ITAB3-MENGE_REG,
               ITAB1-MATNR_REG TO ITAB3-MATNR_REG.
               APPEND ITAB3.
               CHECK = 'X'.
               ENDLOOP.
    IF CHECK = ' '.
       ITAB3-MATNR_REG  = SPACE.
               ITAB3-MENGE_REG = SPACE.
              APPEND ITAB3.
              CLEAR CHECK.
              ENDIF.
    ENDLOOP.
    IS IT RIGHT?

  • Comparing 3 values at a time

    Hi,
    Is it possible to compare 3 values at a shot and map accordingly.
    say if there are A1,A2 and A3 - can we compare all the three and assign a respective value to target field?
    i.e, if A1 then 10, if A2 then 20 and if A3 then send blank.
    I am able to compare only 2 values using if-else condition.
    Please provide the inputs for the same.
    Regards,
    Rajkamal

    yes you can compare using graphical functions and udf too..
    graphical function use AND Functions
    A1---------------
                              BOOLEAN EUQLS-------------
    CONSTANT[10]--                                                                               
    AND FUNCTION-
    A1---------------
                              BOOLEAN EUQLS-------------
    CONSTANT[20]--                                                                               
    ANDFUNCTION              ------->Target
                                                                                    A1---------------
                              BOOLEAN EUQLS-------------
    CONSTANT[value]--
    or use udf
    pass three arguments as inout
    If(A==10&&A2==20&&A3==30)
    RETUNRN expected result.
    Regards.
    Raj
    some ssmal chnages rwquired,i have not tersted this

  • Comparing String values against a collection of Names in a Hash Table

    Objective:
    Is to make a script that will import a csv file containing two values: "Name" and "Price". This would ideally be stored in a hash table with the key name of "Name" and the value being "Price". The second part would be
    importing a second csv file that has a list of names to compare too. If it finds a similar match to a key name in the hash table and then it will add that to a new array with the price. At the end it would add all the prices and give you a total value.
    The Problem to Solve:
    In the real world people have a tendency to not write names exactly the same way, for example I am looking at a list of books to buy in an eBay auction. In the auction they provide a text list of all the names of books for sale. In my price guide it has all
    the names and dollar values of each book. The wording of the way each book is named could differ from the person who writes it and what is actually in my reference pricing list. An example might be "The Black Sheep" vs "Black Sheep" or
    "Moby-Dick" vs "Moby Dick".
    I've tried making a script and comparing these values using the -like operator and have only had about 70% accuracy. Is there a way to increase that by 
    comparing the characters instead of likeness of words? I'm not really sure how to solve this issue as it's very hard to do quality check on the input when your talking about hundreds of names in the list. Is there a better way to compare values in power-shell
    then the "like" operator? Do I need to use a database instead of a hash table? In the real world I feel like a search engine would know the differences in these variations and still provide the desired results so why not for this type of application?
    In other words, create a bit more intelligence to say well it's not a 100% match but 90% so that is close enough, add it to the array as a match and add the price etc..
    I'd be curious as to any thoughts on this? Maybe a scripting language with better matching for text?

    Have you considered setting up a manual correction process that "learns" as you make corrections, automatically building a look up table of possible spellings of each Name?  If you get an exact match, use it.  If not, go to the look up
    table and see if there's been a previous entry with the same spelling and what it was corrected to.
    [string](0..33|%{[char][int](46+("686552495351636652556262185355647068516270555358646562655775 0645570").substring(($_*2),2))})-replace " "

Maybe you are looking for

  • Program Monitor Sync Off When using Color correction

    it takes about few splits of a sec never timed it, but when im using any effect an i move a slider or anything the monitor doesnt update for a while. so makes working in the moment impossible. I have an I7 16gb ram with a 2gb nvidia with cuda.  I don

  • PassCode (Auto Lock) Problems

    My iPhone is PassCode locked, however the only option I have for auto lock is immediately. My wife's iPhone4 has options like immediately, 1, 2, 3, 4, 5 minutes. Any idea what's happening? Thanks

  • Some strange after create a new database

    Hi All, I try to create a new database on the Win 2000 ORA8I server (existing have 1 db already), after using the DBCA create it, I try to connect to new DB, but I found that all the control file are point to the old db's. I've check that there are 2

  • Mini fails to boot

    I have a mini which gets stuck at the boot screen and never loads the OS. Normally I would put a snow leopard disk in to use the disk utility but it's not booting off of disc nor am I able to successfully network boot. I tried resetting the PRAM and

  • Will Element 13 support the new Sony A7 II Camera in RAW?

    I recently purchased the Sony A7 II and my old LR does not recognize the files produced by this camera.  I want to purchase Element 13 but before I do I would like to know if I it will work?  Thank you in advance for any help.