Case insensitive query on a CLOB item

Hi all
i have this problem...
i have a table which contains a CLOB column
in my form i have a block based on this table.
i noticed that when i query the form on the clob item , it doesn't accept the case insensitive query property.
(so if i query %AA% the form doesn't show 'Aa' or the 'aa')
can you please help me?
thanks!

Forms is not really instrumented to query clobs directly. Google "oracle forms and clob" to see some suggestions on how to handle clobs in Forms

Similar Messages

  • Case insensitive query from a JSP

    I am using JDeveloper 3.1 to create JSP applications using the wizard for business components for JSP application.
    The default query screen allows a search to be performed on all the fields on the table (using the Findform web bean).
    How can I change the search such that the query is Case Insensitive ?
    Many Thanks,
    Ketan.
    Many Thanks,
    Ketan.

    Forms is not really instrumented to query clobs directly. Google "oracle forms and clob" to see some suggestions on how to handle clobs in Forms

  • SELECT INTO doing case insensitive query?

    Hi all,
    I'm having a problem with a query acting as if it is case-insensitive when I do a "SELECT table.x INTO variable ...". If I do the same query, without the "INTO variable", I get one result, as expected.
    The query is similar to the following:
    SELECT table_id INTO variable FROM table WHERE table.varchar2column = 'name' AND table.integercolumn = int_variable;
    There is a unique constraint forcing the varchar2column / integercolumn values to be unique.
    If the varchar2column has two entries that differ only in case, a regular select statement returns one result. However, in the stored procedure using the INTO, I get the following error message:
    ORA-01422: exact fetch returns more than requested number of rows
    It does not get that if I remove the entry that differs only in letter-case. This is Oracle 10.2.0.1.0, if that matters.
    I need this query to be case sensitive. I'm not a DB expert, I'm just a developer trying to fix a problem. I attempted to run "ALTER session SET nls_sort = binary" in the stored procedure, but I guess I can't do that...
    Any suggestions would be appreciated.

    791307 wrote:
    SELECT table_id INTO variable FROM table WHERE table.varchar2column = 'name' AND table.integercolumn = int_variable;
    ...When you say, "...AND table.integercolumn = int_variable;" What is the name of int_variable? Does that name match some column name? Could you post the table creats and a complete sample PL/SQL block with your issue?
    One of the things that gets me every once in awhile is having a variable name that matches a column name. In that case the column name is used inside the select statement, not the variable. To avoid that issue, I use v_ for all my variables. (Others have different standard prefixes.)
    I only point this out, because it might be given results that look case insensitive on the varchar2 column, but is really an issue with the integer column matching to a variable:
    SQL> drop table T;
    Table dropped.
    SQL> create table T (id number constraint T_PK primary key
      2      , Varchar2Data varchar2(20)
      3      , NumberData number(38)
      4      , constraint T_UK1 unique (Varchar2Data, NumberData)
      5  );
    Table created.
    SQL> insert into T values (1, 'STRING', 100);
    1 row created.
    SQL> insert into T values (2, 'string', 200);
    1 row created.
    SQL> insert into T values (3, 'STRING', 300);
    1 row created.
    SQL> select * from T where Varchar2Data = 'STRING' and NumberData = 100;
            ID VARCHAR2DATA         NUMBERDATA
             1 STRING                      100
    SQL> declare
      2      NumberData number(38);
      3      Id Number;
      4  begin
      5      NumberData := 100;
      6      select Id into Id
      7      from T
      8      where T.Varchar2Data = 'STRING'
      9      and T.NumberData = NumberData;
    10      DBMS_OUTPUT.PUT_LINE(Id);
    11  end;
    12  /
    declare
    ERROR at line 1:
    ORA-01422: exact fetch returns more than requested number of rows
    ORA-06512: at line 6
    SQL> declare
      2      v_NumberData number(38);
      3      v_Id Number;
      4  begin
      5      v_NumberData := 100;
      6      select Id into v_Id
      7      from T
      8      where T.Varchar2Data = 'STRING'
      9      and T.NumberData = v_NumberData;
    10      DBMS_OUTPUT.PUT_LINE(v_Id);
    11  end;
    12  /
    1
    PL/SQL procedure successfully completed.
    SQL>

  • Case insensitive query or search in Form

    Hi,
    I have created a form based on a table. If i fill any of the field and then clicks the Query button for saerch it give me the record but it is case sensitive. How can i get this functionality ir-respectative of upeer-case or lower-case.
    Thanks in advance.
    Ejaz

    In the onQuery procedure you find this code:
    if "_convert" and "_operator" is not null then
    "_value" := replace("_value",'''','''''');
    "_where" := "_where" ||'ENAME' || "_operator" || ''''|| "_value" ||''' and ';
    elsif "_convert" and "_operator" is null then
    "_value" := replace("_value",'''','''''');
    "_where" := "_where" ||'ENAME like '''|| "_value" ||''' and ';
    elsif not "_convert" then
    "_where" := "_where" ||'ENAME '|| "_value" ||' and ';
    end if;
    You should modify this to get what you want. However be warned that changing the generated package is not supported and any changes will be lost on regenerating the component.
    Regards,
    Hsiu

  • Case insensitive query

    I'm trying to do a query ignoring case.
    select to_upper(node) from STATUS where to_upper(node) = 'KAN';
    I get ORA-00904 : invalid colum name
    I also tried to use a column alias but got the same result
    select to_upper(node) nnn from STATUS where nnn = 'KAN'
    I'm stuck
    George

    Hi,
    try upper(node) instead of to_upper.
    hth

  • Case Insensitive Querys

    If I have a table that has a column called login_name defined as char(64).
    I currenrly prepare statments that look like:
    select something from some_table where login_name like ?;
    Can I use the following if I wanted to implement a case insensitive query, and are there performance implications?
    select something from some_table where UPPER(login_name) like ?;

    The best way from a performance perspective is to also store the upper (or lower) case form of 'login_name' in an additional column of the table (ucase_login_name), have the application itself convert the parameter value to upper or lower case and the njust do:
    select something from some_table where ucase_login_name like ?;
    As long as any wildcards are at the end of the passed in parameter this will use an index if one is defined on that column.
    Chris

  • SELECT Query to get the Values in Case insensitive Format

    Hi ,
    This is hari,
    I want to select the user name in a table ex: username="HARI" or username='Hari' or username="HaRi" like this
    If i wrote the query like
    select username from userdb where username="Hari";
    it is displaying the records which only matches "Hari" only .
    can anybody help me out on this query asap please....
    the query should return all the results
    which matches any of the following strings as inputs "HARI" or "HaRi" or "hAri" or the like.
    Awaiting for Response,
    Thanks & Regards
    Hari

    Another solution is setting NLS_SORT to CI - case insensitive (or whatever_your_language_is_CI) and NLS_COMP to ANSI:
    SQL> with t as (
      2             select 'HARI' name from dual union all
      3             select 'Hari' name from dual union all
      4             select 'HaRi' name from dual
      5            )
      6  select  *
      7    from  t
      8    where name = 'hArI'
      9  /
    no rows selected
    SQL> alter session set nls_sort = binary_ci
      2  /
    Session altered.
    SQL> alter session set nls_comp=ansi
      2  /
    Session altered.
    SQL> with t as (
      2             select 'HARI' name from dual union all
      3             select 'Hari' name from dual union all
      4             select 'HaRi' name from dual
      5            )
      6  select  *
      7    from  t
      8    where name = 'hArI'
      9  /
    NAME
    HARI
    Hari
    HaRi
    SQL> SY.

  • How to hide "Note that the search is case insensitive" text from Query Region

    Hi,
    When create a search page with Query region : Autocustomizationcriteria mode, page is showing automatically "Note that the search is case insensitive" text is showing automatically.
    this is not needed. can you please let me know how to hide this one from page.
    Regards,
    Ram

    Check this link:
    https://forums.oracle.com/message/9227812#9227812
    --Sushant

  • Query that treats "accents insensitive" and "case insensitive"

    I need to do one query that treats "accents insensitive" and "case insensitive" if possible too.
    I need to have the query below ajusted to return both accent or not accent words:
    with t as
    ( select 'xxxELEIÇÕESyyy' text from dual union all
    select 'xxxELEIÇOESyyy' text from dual union all
    select 'xxxELEICÕESyyy' text from dual)
    select text from t
    where text like '%eleicoes%'; --> i need some filter that result true for both 3 lines

    SQL> with t as
      2  ( select 'xxxELEIÇÕESyyy' text from dual union all
      3  select 'xxxELEIÇOESyyy' text from dual union all
      4  select 'xxxeleiÇOESyyy' text from dual union all
      5  select 'xxxELEICÕESyyy' text from dual)
      6  select text from t
      7  where regexp_like(t.text, '(x|X){3}(ELEI|elei){1}([CcÇç]{1})([ÕOõo]{1})(ES|es){1}(y|Y){3}')
      8 
    SQL> /
    TEXT
    xxxELEIÇÕESyyy
    xxxELEIÇOESyyy
    xxxeleiÇOESyyy
    xxxELEICÕESyyy

  • Select query case insensitive for data type VARG

    Hi Experts,
    I am having trouble in retrieving the results from a table using select query.
    I have a table (Users) as below
    Name (VARG)        Number(INTEGER)
    Murthy             0001
    murthy             0002
    when I am querying the table with select query as -
    select * from Users where Name = 'Murthy'
    this query is returning only one record which matches with capital letter of 'M', though both the record names are same.
    I have seen in IBM forum to make the select query as case insensitive using the UPPER key word, I have tried this as below -
    select * from Users where UPPER(Name) = 'MURTHY'
    But this query is not working in my case...
    My DB2 version is 8.1.5
    Can any one please help in fixing this problem...
    Thanks in Advance,
    Murthy

    Hi Murthy,
    your query is the right to one to select both records. I don't see why it doesn't work.
    Are you sure you posted the query that you have executed ?
    What is the result of this query ?
    But i don't really know how an VARG (Varying-length graphic string) will work. It could be that the UPPER-Function will work in another way as it works on VARCHAR.
    regards
    Kay

  • Performing a case insensitive table storage query: Storage client 3.0

    I'm using Storage Client 3.0 and performing queries against entity properties such as a string value for email address.
    I'm using the TableQuery class and my query looks something like this:
    CloudTable accountsTable = tableClient.GetTableReference(Settings.AccountTable);
    TableQuery<Account> rangeQuery = new TableQuery<Account>().Where(
    TableQuery.CombineFilters(
    TableQuery.GenerateFilterCondition("PartitionKey", QueryComparisons.Equal, "account"),
    TableOperators.And,
    TableQuery.GenerateFilterCondition("Email", QueryComparisons.Equal, email)));
    var results = accountsTable.ExecuteQuery(rangeQuery).ToList();
    This works fine when the entity I'm searching for matches the case of my search term.  But how can I perform a case insensitive search?  I think this was possible when using linq queries but how do I accomplish this in the new storage client?
    thanks

    Hi,
    As far as I know, azure table storage didn't support some linq operator, such as this page  (http://msdn.microsoft.com/en-us/library/dd135725.aspx) shown. You could use some common
    linq methods, as those sample (http://blogs.msdn.com/b/kylemc/archive/2010/11/22/windows-azure-table-storage-linq-support.aspx).
    Also, I suggest you could refer to same thread (http://stackoverflow.com/questions/8805759/azure-table-storage-query-in-net-with-property-names-unknown-at-design-time).
    You could change your code to linq format and try it.
    Thanks.
    Any question, please let me know.
    Thanks.
    Will
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Case insensitive search mode by jbo:DataQuery

    I'm working on a BC4J JSP project. I cannot find a way to search in the case insensitive mode. I'm using JDeveloper 9.0.3.1. I looked in the DataQueryComponent.jsp, the xxxx_Query.jsp, and all the files generated under the ViewObject to find a way to accomplish this but no luck. Please advise. Thank you.

    One thing you can do is modify the query handler. If it's a straight JSP app (no uix/struts) you are probably using DataHandler.jsp for you handling. If this is the case, you can modify the OnEvent section for Search and Add Criteria. They should look like this
    <jbo:OnEvent list="Search, Add Criteria" >
    <% String rowParam = params.getParameter("nRows");
    int nRows = 0;
    if (rowParam != null)
    try { nRows = Integer.parseInt(rowParam); }
    catch (Exception ex) { }
    %>
    <jbo:ViewCriteria id="vc" datasource="ds" action="new">
    <% for (int index=0; index < nRows; index++)
    String criteriaRowId = "row" + index;
    %>
    <jbo:CriteriaRow id="<%=criteriaRowId%>" >
    <jbo:AttributeIterate id="attrvc" datasource="ds" queriableonly="true">
    <% String item = attrvc.getName();
    String value = params.getParameter("row" + index + "_" + item);
    %>
    <jbo:Criteria dataitem="<%=item%>" value="<%=value%>" />
    </jbo:AttributeIterate>
    </jbo:CriteriaRow>
    <% } %>
    </jbo:ViewCriteria>
    </jbo:OnEvent>
    I added a line just about the <jbo:Criteria> line that converts the value to uppercase like this:
    if (value !=null) { value=value.toUpperCase(); }
    Hope that helps!

  • Query to mimic the items tab of the Sales Analysis report.

    Hi there,
    I'm currently looking to create a query that mimics the behaviour of the Sales Analysis report in B1. The items tab of the Sales Analysis report provides all the data I require - the only issue is that I would like to merge this data with some other data regarding current on hand stock quantities etc. and therefore I would like to be able to pull out the query behind the Sales Analysis report.
    I'm assuming this cannot be done and therefore I'm attempting to build a query to replicate the results. The query needs to show Item No, Item Description, Quantity Sold, Sales Amt (in system currency), Gross Profit and Gross Profit % for items within a given period.
    If this can be done relatively easily, can the query then be modified to show all items (including items that haven't sold in the date range) merely with '0' for Quantity Sold, Sales Amt etc. if the item hasn't been sold in the period, and the appropriate figures if each of these columns if the item has sold. I assume some kind of CASE statement can be used to generate this.
    So the query needs to show Item No, Item Description, Current quantity in stock, Quantity Sold, Sales Amt (in system currency), Gross Profit and Gross Profit % for all items within a given date range.
    I hope you can assist me with this problem.
    Thanks
    Grant.

    Hi,
    Thanks Gordon that was exactly what I needed.
    I've been trying to add some additional columns to the query but I'm experiencing some errors and I can't quite tell why.
    Basically, here's the code from another working query I have which I wish to merge into the query you've suggested above:
    SELECT T0.[ItemCode],
    T0.[ItemName],
    T3.[ItmsGrpNam],
    T4.[Name] AS [Sub-Category],
    T5.[Name] AS [Sub-Sub-Category],
    T0.[CardCode] AS [Pref Supplier],
    T6.[FirmName] AS [Brand],
    T0.[U_Range],
    T0.[OnHand],
    CASE WHEN T0.[StockValue] = 0 THEN 0 ELSE T0.[StockValue] END AS [StockValue],
    T1.[Price] AS [PBK GBP Price],
    CASE WHEN T0.[OnHand] = 0 THEN T0.[LastPurPrc] ELSE T0.[StockValue]/T0.[OnHand] END AS [Ave Cost],
    CASE WHEN T0.[OnHand] = 0 THEN T1.[Price]-T0.[LastPurPrc] ELSE CASE WHEN T0.[OnHand] > 0 THEN T1.[Price]-T0.[StockValue]/T0.[OnHand] END END AS [Margin],
    CASE WHEN T0.[OnHand] = 0 AND T0.[LastPurPrc] = 0 THEN 0 ELSE CASE WHEN T0.[OnHand] > 0 AND (T0.[StockValue]/T0.[OnHand]) = 0 THEN 0 ELSE CASE WHEN T0.[OnHand] = 0 THEN (T1.[Price]-T0.[LastPurPrc])/T1.[Price]*100 ELSE CASE WHEN T0.[OnHand] > 0 THEN (T1.[Price]-T0.[StockValue]/T0.[OnHand])/T1.[Price]*100 END END END END AS [Margin %],
    T0.[LastPurPrc]
    FROM [dbo].[OITM]  T0 INNER JOIN [dbo].[ITM1]  T1 ON T0.ItemCode = T1.ItemCode INNER JOIN [dbo].[OITB]  T3 ON T0.ItmsGrpCod = T3.ItmsGrpCod LEFT OUTER JOIN [dbo].[@U_SUBCATEGORY]  T4 ON T0.U_Subcategory = T4.Code LEFT OUTER JOIN [dbo].[@U_SUBSUBCATEGORY]  T5 ON T0.U_SubSubCategory = T5.Code INNER JOIN OMRC T6 ON T0.FirmCode = T6.FirmCode
    WHERE T0.[OnHand] >= 0 and T0.U_Range not in ('E','X')  
    ORDER BY T0.[ItemCode]
    Essentially I just wish to add the fields which are specified in the query above, but not in the query you've already suggested:
    SELECT T0.ItemCode,
    Max(T0.ItemName),
    Max(IsNull(T0.OnHand,0)) 'In Stock',
    SUM(IsNull(T1.Quantity,0)) 'Quantity',
    Sum(IsNull(T1.LineTotal,0)) 'Sales Amt',
    SUM(IsNull(T1.GrssProfit,0)) 'Gross Profit',
    Case WHEN Sum(Isnull(T1.LineTotal,0)) = 0 THEN 0 ELSE
    SUM(IsNUll(T1.GrssProfit,0))/Sum(Isnull(T1.LineTotal,0)) * 100 END 'Gross Profit %'
    FROM dbo.OITM T0
    LEFT JOIN dbo.INV1 T1 ON T1.ItemCode=T0.ItemCode
    LEFT JOIN dbo.OINV T2 ON T2.DocEntry=T1.DocEntry AND T2.DocDate Between [%0] AND [%1]
    GROUP BY T0.ItemCode
    I was hoping it would be fairly straight forward but so far I've had limited success.
    What am I missing here?
    Thanks in advance!

  • Error in a report after enabling case insensitive search in conn pool prop

    Hi All,
    I put the below code in connection pool's connection string to enable case insensitive search.
    alter session set NLS_SORT=BINARY_CI
    alter session set NLS_COMP=LINGUISTIC
    After putting this code one of my report started giving the below error which was working fine otherwise.
    Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
    State: HY000. Code: 10058. NQODBC SQL_STATE: HY000 nQSError: 10058 A general error has occurred. nQSError: 16001 ODBC error state: S1000 code: 1791 message: OracleODBCOraORA-01791: not a SELECTed expression. nQSError: 16001 ODBC error state: S1000 code: 1791 message: OracleODBCOraORA-01791: not a SELECTed expression. nQSError: 16015 SQL statement execution failed. (HY000)
    The report gives error for the below divide condition when I select a column from a different dimension (eg: region)
    COUNT(DISTINCT RMA.RMA)/COUNT(DISTINCT User."User Name")
    Can anyone please throw a light why this is happening.

    Below is the SQL which is throwing error in OBIEE. It was working fine when I tried running it in toad:
    select T1609.ATTRIB_05 as c1,
    count(distinct T1609.ATTRIB_42) as c2,
    TRUNC(T1159.FSCL_WEEK_START_DT) as c3
    from
    WC_DAY_D T1159 /* RMA_RECEIVED_DT(WC_DAY_D) */ ,
    WC_RMA_D T571,
    WC_FV_FA_D T1609,
    WC_FV_FA_F T1679
    where ( T571.ROW_WID = T1679.RMA_WID and T1159.ROW_WID = T1679.RMA_RECEIVED_WID and T1609.ROW_WID = T1679.FV_FA_WID and T1609.ATTRIB_39 <> 'FV' and (T571.STATUS_CD in ('2nd FA', '2nd FA Review', 'Closed')) and TRUNC(T1609.TODO_ACTL_END_DT) is not null and TRUNC(T1159.FSCL_WEEK_START_DT) between TIMESTAMP '2009-03-22 00:00:00' and TIMESTAMP '2009-04-12 00:00:00' )
    group by T1609.ATTRIB_05, TRUNC(T1159.FSCL_WEEK_START_DT)
    order by c3
    -------------------- Query Status: Query Failed: [nQSError: 16001] ODBC error state: S1000 code: 1791 message: [Oracle][ODBC][Ora]ORA-01791: not a SELECTed expression.
    [nQSError: 16001] ODBC error state: S1000 code: 1791 message: [Oracle][ODBC][Ora]ORA-01791: not a SELECTed expression.
    [nQSError: 16015] SQL statement execution failed.

  • Case Insensitive Indexes

    In relation to switching on case insensitive queries using
    alter session set NLS_COMP=LINGUISTIC;Can anyone answer the following?
    >
    Yes, it works.... but I can't for the life of me figure out how to build a linguistic index that the LIKE clause will actually use. Building an index thus, for example:
    create index bin_ai on names(NLSSORT("NAME",'nls_sort=''BINARY_AI'''));
    makes an index which does get used to good effect by queries such as
    select name from names where name = 'Johny Jacobson';
    but not by
    select name from names where name like 'Johny%';
    Hence, in a real-world test with 100,000 records, the LIKE query runs about 100 times slower than the '=' query (3 sec compared to 0.03 sec). Not very scalable. Is there a way to speed this up??
    Also is it possible to set session variables such as nls_comp on a database/schema/user level?

    Hi,
    select name from names where name like 'Johny%';Performance when using the SQL "like" clause can be tricky because the wildcard "%" operator can invalidate the index. For example a last_name index would be OK with a "like 'SMI%'" query, but unusable with "like '%SMI%'.
    One obscure trick for indexing queries "like '%SON'" is to create a REVERSE index and them programmatically reverse the like clause to read "like 'NOS%'", effectively indexing on the other side of the text.
    You might want to look at Oracle*text indexes, if your database has low DML:
    http://www.dba-oracle.com/oracle_tips_like_sql_index.htm
    If you are 10gr2:
    Oracle 10g release 2 has now introduced a case insensitive search method for SQL that avoids index invalidation and unnecessary full-table scans. You can also employ Oracle text indexes to remove full-table scans when using the LIKE operator. Prior to Oracle10g release 2 case insensitive queries required special planning:
    1 - Transform data in the query to make it case insensitive (note that this can invalidate indexes without a function-based index):
    create index upper_full_name on customer ( upper(full_name));
    select full_name from customer
    where upper(full_name) = 'DON BURLESON';
    2 - Use a trigger to transform the data to make it case insensitive (or store the data with the to_lower or to_upper BIF.
    3 - Use Alter session commands:
    alter session set NLS_COMP=ANSI;
    alter session set NLS_SORT=GENERIC_BASELETTER;
    select * from customer where full_name = 'Don Burleson'
    Hope this helps. . .
    Don Burleson
    Oracle Press author

Maybe you are looking for

  • Saving changes in Word document

    Hi all, I am using the 30-day trial version of Iwork '09 and have been running into the following problem: Whenever I save a Pages document as a Word document, as soon as I make changes to the document and click Save just to save these changes, the c

  • Macbook Pro 13 Warranty

    I am about to buy a Macbook Pro 13, should I go for and do I need the extra 3 years warranty?

  • Hyperion Planning form timeout via Open Form under SV Data Source Manager

    Power User can't open one particular big Planning form in Excel. Takes about 30 secs and gets net retry intverval timeout error. The same user can ad-hoc (one menu option up in the SV Data Source Manager) the form in question and can open the other (

  • Creating Client 800 For ECC 6.0

    Hi, I have installed ECC 6.0 IDES in my PC,i able use 001 client with DDIC user name but iam unable to open 800 client. Can you please tell me how to create client 800 in ECC. Thanks in Advance, Regards, Balu.

  • Exporting mp4 to WMV - only 30 seconds transfers

    I am a new QT Pro user (version 7). I need to convert some files to WMV. I have several files normally in the range of 2 minutes each. When I convert the file to WMV the clip only ends up being 30 seconds long. Any ideas / thoughts?