Query to apply regexp_like for patterns specified in different table

Hi all,
with table trap_store as ( vb clob) and table conf as (patten varchar2(20))
Need to retrieve records from trap_store where data in vb column matches patterns in conf table.
Presently planning to use regexp_like function ie; regexp_like(vb,'Start').
In the above query, have hardcoded the pattern as 'Start'. But, Patterns are present in different conf table. Each row of trap_store table ie; each value of vb column in trap_store table should be matched with all the patterns of conf table.
How to apply all the patterns of conf table ?

It's possible to write a script with a LOOP over the pattern table to generate queries or generate a filter, and then execute it via Dynamic SQL (depends on the pattern table size)

Similar Messages

  • Global display options for equal columns of different tables

    Hi,
    is it possible to create some kind of templates for tables which are nearly the same! I mean different table names, different content and some columns are equal.
    e.g. I've got a a lot of Error tables, in every table there is a column named Reload Flag, which should be displayed as a List of value, can i set this by default. Or for example I've got a column named Error message and i display it as a standard report column, but i always have to edit the column formatting, because the column is very broad. I have to change the CSS Style ( {width:30em;} )!
    THX Mat

    Hi,
    Yes, It must be working using rowid since its not mention anywhere, I could not post it. But I too think so.
    check the below block
    SQL> Declare
      2  v_mydept1 emp.deptno%TYPE;
      3  v_mydept2 dept.loc%TYPE;
      4  CURSOR C1 IS SELECT e.deptno,d.loc
      5  FROM emp e,dept d
      6  WHERE e.deptno = d.deptno
      7  and empno=7900
      8  FOR UPDATE of e.sal;
      9  Begin
    10  OPEN C1;
    11  LOOP
    12  FETCH C1 INTO v_mydept1,v_mydept2;
    13  Dbms_output.put_line(v_mydept2);
    14  Dbms_output.put_line(v_mydept1);
    15  EXIT WHEN C1%NOTFOUND;
    16  UPDATE dept SET loc = 'NY' WHERE CURRENT OF C1;
    17  select loc into v_mydept2 from dept where deptno=v_mydept1;
    18  Dbms_output.put_line('Record updated '||v_mydept2);
    19  End loop;
    20  COMMIT;
    21  End;
    22  /
    Declare
    ERROR at line 1:
    ORA-01410: invalid ROWID
    ORA-06512: at line 16The logic doesnot make sense, but if you can notice the error speaks about rowid.
    For update locks the specific rows listed in the cursor and Where Current Of Clause must be taking in account the rows as per thier ROWID.
    Twinkle
    Edited by: Twinkle on Apr 8, 2010 4:28 PM

  • Send an email for recipients specified in a table (Workflow)

    Hi experts,
    I started programming Workflow few weeks ago and I've got some doubts. I will explain what I'm trying to develop:
    We create a Workflow in order to synchronise creation of functional location with asset master (copying the way of synchronisation of equipment and asset master). Finally, it works!
    The last problem I have is how to sent an email from a "Z" table (where are specified all the emails), and not only for the user that triggers the event of creating and asset.
    This table is used for sending emails with user-exits of modification when an equipment/functional location is modified. But there is no user-exit after save event in assets, so I can't do the same codification.
    Could anyone help me? Or recommend me a way to achieved what I wanted to do?
    Lots of thanks.
    Javi

    Hello,
    You have a working Workflow and you want to send an email based on a Z table.... what's the problem?
    I don't see how user exits are involved.
    regards
    Rick Bakker
    Hanabi Technology

  • Case to query multiple values and return single value to different table

    Hi this is my first table:
    with Table_1
    as
          select 'CAR' Object, 2000 Policy    from dual
          union all
          select 'BIKE' Object, 2000 Policy  from dual
          union all
          select 'HOUSE' Object, 2000 Policy  from dual
          union all
          select 'MOBILE' Object, 2000 Policy  from dual
          union all
          select 'MONEY' Object, 2000 Policy  from dual
          union all
          select 'CREDIT' Object, 2000 Policy  from dual
          union all
          select 'SCOOTER' Object, 2001 Policy    from dual
          union all
          select 'BIKE' Object, 2001 Policy  from dual
          union all
          select 'BEACH' Object, 2001 Policy  from dual
          union all
          select 'HOUSE' Object, 2001 Policy  from dual
          union all
          select 'MONEY' Object, 2001 Policy  from dual
          union all
          select 'CREDIT' Object, 2001 Policy  from dual
          union all
          select 'DOOR' Object, 2002 Policy    from dual
          union all
          select 'BIKE' Object, 2002 Policy  from dual
          union all
          select 'GARDEN' Object, 2002 Policy  from dual
          union all
          select 'MOBILE' Object, 2002 Policy  from dual
          union all
          select 'MONEY' Object, 2002 Policy  from dual
          union all
          select 'CREDIT' Object, 2002 Policy  from dual
    select * from Table_1I need to Query the object column of table_1 for CAR or HOUSE and if they are present then returns 'Y' otherwise 'N'. This table_1 will link to table_2 via Policy and the result will be table_3
    with Table_2
    as
          select '21' AGE, 2000 Policy  from dual
          union all
          select '22' AGE, 2001 Policy from dual
          union all
          select '27' AGE, 2002 Policy from dual
    select * from Table_2
    with Table_3
    as
          select '21' AGE, 2000 Policy, 'Y'  Many_Obj    from dual
          union all
          select '22' AGE, 2001 Policy,  'Y' Many_Obj from dual
          union all
          select '27' AGE, 2002 Policy,  'N' Many_Obj from dual
    select * from Table_3Thanks in advance
    Banner:
    Oracle Database 11g Release 11.2.0.2.0 - 64bit Production
    PL/SQL Release 11.2.0.2.0 - Production
    "CORE 11.2.0.2.0 Production"
    TNS for Linux: Version 11.2.0.2.0 - Production
    NLSRTL Version 11.2.0.2.0 - Production
    !

    Thanks for the insert statements.
    Here is one way
    with Table_1
    as
          select 'CAR' Object, 2000 Policy    from dual
          union all
          select 'BIKE' Object, 2000 Policy  from dual
          union all
          select 'HOUSE' Object, 2000 Policy  from dual
          union all
          select 'MOBILE' Object, 2000 Policy  from dual
          union all
          select 'MONEY' Object, 2000 Policy  from dual
          union all
          select 'CREDIT' Object, 2000 Policy  from dual
          union all
          select 'SCOOTER' Object, 2001 Policy    from dual
          union all
          select 'BIKE' Object, 2001 Policy  from dual
          union all
          select 'BEACH' Object, 2001 Policy  from dual
          union all
          select 'HOUSE' Object, 2001 Policy  from dual
          union all
          select 'MONEY' Object, 2001 Policy  from dual
          union all
          select 'CREDIT' Object, 2001 Policy  from dual
          union all
          select 'DOOR' Object, 2002 Policy    from dual
          union all
          select 'BIKE' Object, 2002 Policy  from dual
          union all
          select 'GARDEN' Object, 2002 Policy  from dual
          union all
          select 'MOBILE' Object, 2002 Policy  from dual
          union all
          select 'MONEY' Object, 2002 Policy  from dual
          union all
          select 'CREDIT' Object, 2002 Policy  from dual
    Table_2
    as
          select '21' AGE, 2000 Policy  from dual
          union all
          select '22' AGE, 2001 Policy from dual
          union all
          select '27' AGE, 2002 Policy from dual
    SELECT
         age,
         policy,
         Many_Obj
    from
    SELECT
         t2.age,
         t2.policy,
         CASE
              WHEN SUM(
                        CASE
                             WHEN t1.object IN ('CAR','HOUSE')
                             THEN 1
                             ELSE 0
                        END) over( PARTITION BY t2.age,t2.policy) > 0
              THEN 'Y'
              ELSE 'N'
         END Many_Obj,
         row_number() over (PARTITION BY t2.age,t2.policy order by 1) rn
    FROM
         Table_1 t1,
         Table_2 t2
    WHERE
         t1.policy = t2.policy
    where rn = 1;
    AGE POLICY                 MANY_OBJ
    21  2000                   Y       
    22  2001                   Y       
    27  2002                   N        I would advise you to spend some time learning analytic questions and using CASE expressions.

  • Using Oracle's Parallel Server for synchronizing databases with different tables

    Hello,
    I have a problem and I was searching through the Oracle documentation.
    Then I mentioned the Oracle's Parallel Server (OPS) feature.
    The problem I want to fix is the following:
    I want to make a copy of a database. Subsequently I want to make changes to the copy of the original database. (possible changes could be extra columns).
    Now I want to synchronize the data of both databases...
    Is it possible to use Oracle's Parallel Server feature for this task?
    Greets,
    Harm

    Hello,
    I have a problem and I was searching through the Oracle documentation.
    Then I mentioned the Oracle's Parallel Server (OPS) feature.
    The problem I want to fix is the following:
    I want to make a copy of a database. Subsequently I want to make changes to the copy of the original database. (possible changes could be extra columns).
    Now I want to synchronize the data of both databases...
    Is it possible to use Oracle's Parallel Server feature for this task?
    Greets,
    Harm

  • The problem about inputDate with pattern specified for 24h time.

    Hi all,
    i want to use pattern specified for 24h time for inputDate,
    format mask like:yyyy-MM-dd HH:mm:ss
    at runtime,the inputDate value is :2011/09/27 22:05:59 ,
    but the value is 10:05:59 in Calendar Dialog.
    then click OK button,the inputDate value becomes :2011/09/27 10:05:59.
    This is normal?
    thanks in advance.

    Hi,
    Did you try as follow,
    using <af:convertDateTime>
    <af:inputDate >
              <af:convertDateTime pattern="yyyy-MM-dd HH:mm:ss"/>
    </af:inputDate>See
    http://download.oracle.com/docs/cd/E12839_01/apirefs.1111/e12419/tagdoc/af_convertDateTime.html
    http://blogs.oracle.com/Didier/entry/how_to_specify_a_second_date_p

  • How  to fire a query for every record in a table, pass values in a loop

    Hi,
    For each record in a table, I want to loop through each record and then fire a query by passing acct, product and date from this table to the where clause of the query. I would have to create a pl/sql block..The output of the query I want to spool from sql developer.
    I need the exact syntax please for doing this.. since i am new to Oracle. Just the template will be enough. I will fill in the query.
    Any help is appreciated as always..
    Regards,
    hena

    904385 wrote:
    Hi,
    For each record in a table, I want to loop through each record and then fire a query by passing acct, product and date from this table to the where clause of the query. I would have to create a pl/sql block..The output of the query I want to spool from sql developer.
    I need the exact syntax please for doing this.. since i am new to Oracle. Just the template will be enough. I will fill in the query.
    Any help is appreciated as always..
    Regards,
    henaHave you ever considered using a JOIN ? It does the same thing as looping through a table and applying that to the where clause of a select on a query, only much, much, much faster and without the need to write any code. SQL is a declarative language, so you specify what you want and not how to do it. It can be bit of a journey to change your thought process if you come from a procedural or object world, but once you get there it's a beautiful view.

  • How can i view and apply new custom patterns without going to preset manager? i had this facility but have now lost it

    how can i view and apply new custom patterns without going to preset manager? i had this facility but have now lost it.  i design patterns but am fairly new to photoshop. i used to be able to click on the drop down menu in patterns in the 'fill' box but cannot now do this.  have i inadvertently clicked on something to turn this facility off?  i now have to go to 'preset manager' and manually move my new design to the first box and click 'done' so that i can use it.

    Which version of photoshop are you using?
    After you define a custom pattern it should be added to the bottom of whatever patterns are already loaded.
    For example, if you define a custom pattern and then go to Edit>Fill>Pattern, the newly defined pattern should have been added to the existing loaded patterns.

  • ORA-20100: AppDomain could not be created for the specified security level

    We recently updated our development environment to Visual Studio 2010. We have previously deployed (with success) .Net stored procedures from Visual Studio 2005 to our Oracle 10gR2 database. I am currently trying to configure a local instance (called local) of Oracle 10gR2 database to test deployment of .Net stored procedures to Oracle 10gR2 via Visual studio 2010 and ODT version 11.2.0.1.2. I have built the demo from the ode developer guide and gotten as far as deploying it but executing the stored procedures from VS 2010 or SQL*Plus produces the following error...
    ORA-20100: AppDomain could not be created for the specified security level
    ORA-06512: at "SYS.DBMS_CLR", line 152
    ORA-06512: at "SCOTT.GETDEPTNO", line 7
    Here is what I have done.
    (Server)
    1. Installed oracle 10gR2 with ODE.Net
    2. Installed Oracle 10gR2 patch set 22
    3. Installed ODE upgrade from Oracle Developer Tools for Visual Studio .NET with Oracle 10g Release 2 ODAC 10.2.0.2.21
    (Client)
    4. Installed Oracle Developer Tools for Visual Studio .NET with Oracle 10g Release 2 ODAC 10.2.0.2.21 (In new client home).
    5. Installed patch set 22 on 10g client home.
    6. Installed Oracle 11g Release 2 ODAC 11.2.0.1.2 with Oracle Developer Tools for Visual Studio(in new 11g client home, only for VS 2010)
    I have made some minor changes (GAC) etc. per the following threads...
    ODE.NET 11.1.0.7.20 on 10g Database?!
    Re: Error: System.TypeInitializationException
    The database appears to be fully functional via TOAD - SQL plus etc. I can't find much on this error but it appears Oracle needs some permissions to launch an ASP.Net application that it does not have. Any help would be GREATLY appreciated, don't hesitate to ask for additional details.

    The KB article is almost what we have apart from theitalic underlined
    part
    Consider the following scenario:
    You use a domain administrator account to log on to a computer that is running Windows 7 or Windows Server 2008 R2.
    You use the Active Directory Users and Computers Microsoft Management Console (MMC) snap-in to connect to a domain controller.
    You open the Properties dialog box of a user account.
    The user account has sole access to a shared folder path that cannot be accessed by the administrator account.
    You set the Remote Desktop Services Home Folderattribute to the shared folder path.
    NoteThis attribute is located on the
    Remote Desktop Services Profiletab.
    You click Apply or OK.
    In this scenario, you receive the following error message:
    The home folder could not be created because: The network name cannot be found.
    Note If you click Apply or OK again, no error message is returned. However, the setting is not saved.
    I think the important bit is
    The user account has sole access to a shared folder path that cannot be accessed by the administrator account.
    We manually create the shares on our NAS and then just want to enter the path in the profile tab, I suppose the question is how to we stop it trying to create the shares ?

  • Adobe Acrobat Standard 9.5 Install Error:  "Error applying transforms please ensure specified transform paths are valid".  Any ideas on how to fix this?

    I had Acrobat Standard 9.5 on a laptop that broke.  Adobe Acrobat Standard is paid for and all I need. I had to get a new PC (Windows 8.1) and I did downloaded Standard 9.5 but when I went to install it the installer gave me an “Error applying transforms please ensure specified transform paths are valid”.  Any ideas on how to fix this?

    Rahul,
    No error numbers other than the message I mentioned previously.
    I tried the transforms repair and it reported no Acrobat product (correct, none yet installed) or no administrative privileges (I am the administrator and have done previous administrative actions).
    When I unzip the Acrobat file this is what is in the setup ini file:
    [Startup]
    RequireOS=Windows XP
    RequireMSI=3.0
    RequireIE=6.0.2600.0
    [Product]
    msi=AcroStan.msi
    Languages=1033;1031;1036
    1033=English (United States)
    1031=German (Germany)
    1036=French (France)
    CmdLine=TRANSFORMS="AcroStan.mst"
    [Windows XP]
    PlatformID=2
    MajorVersion=5
    MinorVersion=1
    ServicePackMajor=2
    [MSI Updater]
    Path=WindowsInstaller-KB893803-v2-x86.exe
    Thoughts?
    Thanks again,
    Tom

  • Insert query for insert all data into table in vb6 but it insert 1 row in table

    This is My insert query in vb6 but it insert 1 row in table
    But i want insert all data in the table which contain the id =1.
    Note that billtabsuport is blank
    i want solution for this
    strSQL = " select * from billtabsuport1 where StockID=" & lblid.Caption
    Set DBrecordset = DBConnection.Execute(strSQL)
    strSQL = " Insert into billtabsuport values('" & DBrecordset("StockID") & "','" & DBrecordset("C_Name") & "','" & DBrecordset("C_Add") & "','" & DBrecordset("C_Mobile") & "','" & DBrecordset("Invoice_No") & "','" & DBrecordset("Date") & "','" & DBrecordset("Order_No") & "','" & DBrecordset("T_Name") & "','" & DBrecordset("Dest") & "','" & DBrecordset("D_Date") & "','" & DBrecordset("Tyres_Serial_No") & "','" & DBrecordset("P_Desc") & "','" & DBrecordset("PR") & "','" & DBrecordset("Branded_NonBranded") & "','" & DBrecordset("Claim_No") & "','" & DBrecordset("Qty") & "','" & DBrecordset("U_Price") & "','" & DBrecordset("I_Value") & "','" & DBrecordset("V_Rate") & "','" & DBrecordset("V_Amt") & "','" & DBrecordset("Size") & "','" & DBrecordset("Pattern") & "','" & DBrecordset("TypesOfStock") & "','" & DBrecordset("TypesOfTube_Flap") & "','" & DBrecordset("VatAmount") & "')"
    DBConnection.Execute (strSQL)

    The syntax for inserting from one set of tables to a new table is:
    insert into newtable
    (field1, field2, etc)
    select somefield1, somefield2, etc
    from some other tables
    where whatever

  • Hi in my sql query i applied like condition (like '%TEST') but it is taking long time

    Hi in my sql query i applied like condition (like '%TEST') but it is taking long time. I applied indexes also,but still i'm facing the same problem. In my databse nearly 2,00,000 records their.

    Hi Manikandan
    Is there a difference in performance between running the query in BEx and WebI?
    have you aggregates in place on the BEx side of things?
    When you say its taking too long to open the report, have you a variable screen coming up for the report and is that what is taking the time or is it the report execution.
    With regards
    Gill

  • Which Pattern to apply ? Can Pattern can be applied .. ?

    Hi All,
    I have base class "BaseClassA" which do all my basic validation of a function. There are approx 10 validations are there.
    Now my issue is that I need to add New Validation to the BaseClassA, how ever, I dont want to touch the "BaseClassA" code, as it my new validations is case-by-case, not mandatory like what 10 validations of current BasicClass.
    My BasicClass constructor currently calls the all 10 validations now ..
    Can I apply any particular pattern for the case ? Or just a subclass strategy will done ?
    Can any one comment/suggest on the same
    Thanks n Advance
    Abhilash

    Hi,
    Thanks for that quick response.
    My BasicClass has got all validations calls in single method, .i,e it cheques for Zero amount , max limit etc ..
    if(amount >0 ) {return false;}
    if(amount >Limit ) {return false;}
    Now in between these 10 validations, as case need my validation to be done as 3rd or 4th .. so it is a Insert one more validation as required.. so a small catch here ..
    Else as you have suggested was the simplest approach ..
    Regards
    Abhi

  • Only one Apply button for Dashboard Prompt in obiee

    Hi experts,
    We have a need wer we need to place prompts at specified places like one at right top then next 3 one below other. But only one Apply button.
    Please let me know how to customize OBIEE 11.1.1.5 to achieve this.
    Thanks in advance.

    Hi,
    You are using OBIEE 11g ,so constrain the second report should be on the first prompt.I mean,In the second prompt properties we have an option like "based on the other prompt";where you need to give the first prompt column name.like wise third prompt also.
    Then you will get only one apply button for 3 prompts.
    mar if helpful/correct..
    thanks,
    prassu

  • Apply patch for 10g

    Hi, Good morning:
    I am trying to apply patch for my newly installed Oracle10.2.0.1, I downloaded the Opatch utility and extracted it directly into oracle_home, and then I downloaded the latest patch 5500927 and extracted into oracle_home/opatch....
    Now, if I do ' opatch inventory ' under oracle_home/optach, it will give
    D:\Oracle10g\OPatch>opatch lsinventory
    The system cannot find the file specified.
    Java could not be located. OPatch cannot proceed!
    OPatch failed with error code = 1
    If I do 'opatch lsinventory ' under oracle_home/opatch/5500927 it will give :
    D:\Oracle10g\OPatch>cd 5500927
    D:\Oracle10g\OPatch\5500927>opatch lsinventory
    'opatch' is not recognized as an internal or external command,
    operable program or batch file.
    I know I have JVM in my machine, and the JDK is version 1.4...
    Can anyone help me ? what did I do wrong?
    Thanks a lot.
    Wendy

    what a sec..the home does not look right, did you change it on installation?
    set oracle_home=d:\oracle\product\10.2.0\db_1
    set oracle_sid=your_sid
    opatch lsinventory
    if that doesn't work, look at your PATH, see what is going on there
    you might want to put the "opatch" sub-dir into your path..or create a couple of CMD files to set it all the time.

Maybe you are looking for

  • Looking for a good laser printer for OSX 10.6.8

    I need a decent laser printer.  Using Macbook Pro with OSX 10.6.8.  I've given up trying to get the drivers to work on our office Xerox Workcentre 7328.  I keep getting the "OTC at end of life" error and I'm sick of trying to download drivers and try

  • About Logitech 230 5.1 with Soundblaster 24-bit l

    Hello, I really need help from someone. I just bought Logitech 230 5. speakersystem and have got Soundblaster 24-bit li've at the moment. When I installed the speakers and tested them there was som frequent snapping/clicking sound in the fifth speake

  • Application Exceptions for User Feedback

    Hi all! I guess this is a best practice question. I have a struts-based web app that contains various forms and fields that the user can interact with. When a user is filling out a form, I want to validate that the information s/he is inputting is co

  • Can't Manually Change Collection Sort Order

    When trying to manually change the sort order of any collection I get the following error message: Database "/Users/Dan Donovan/Pictures/Lightroom/Lightroom 5 Catalog.lrcat": AgLibraryCollectionImageOzSortOrder.positionInCollection may not be NULL  

  • I replaced my Harddrive, Adobe CS2 askes for activation, but error code 24:24 comes up

    After replacing my Harddrive, Adobe CS2 wants to by reactivated, by activating error code 24:24 is showing, I was asked for phone activation, but several try´s I was told phonactivation is not supported anymore. Can someone help me?