splitting the query string values

all,
I do not remember this, but my problem is that I have a collection of forwarded to my query as string values "X 234234: 23466 X: X 03287: X 457675 ', so my request should be able to divide each data value and use in the filter as below,

Select * from emp where EmpID in ("X 234234: 23466 X: X 03287: X 457675")

so, how can I divide each individual value and pass through the filter?

Thank you.

SELECT trim(x.column_value.extract('e/text () ')) CLO
Of
TABLE (XMLSEQUENCE (XMLTYPE (""
|| REPLACE ('1:2:3:4:6:7:8',': ','
')
|| ((("
").extract('e/e'))) x

Try customizing the syntax above using the column in the function replace instead of my hard-coded string and pass it to the filter predicate using an in operator.

Edited by: Chandrakaanth Ramamurthy on April 25, 2013 16:29

Tags: Database

Similar Questions

  • How to store the query string value in the scope of the session in webcenter spaces?

    Hello

    I want to store the query string value (which is given from URL) in the sessionScope variable. According to the value of sessionScope beacause I went some components inside my taskflow. Can someone help me how to store this value in the scope of the session. I use webcenter spaces for my application development.

    Thank you

    Ashok.

    Please see the article below

    How to pass a parameter of argument the query URL to a parameter input workflow? (Doc ID 1545808.1).

  • PHP, handling # in a passage of the string in the query string

    I'm new to PHP the world ASP. I'm working on a shopping cart where, I'm passing the name of the item through the query string in the processcart.php file. It works fine until I have put a sign # in the name of the element. Is there a good way to manage the channels with signs # among them.

    David

    DEPearson wrote:
    > I'm new to PHP the world ASP. I'm working on a shopping cart where I
    > pass the option through the query string name in the processcart.php file. It works
    > great until I have put a sign # in the name of the element. Is there a good way to manage
    > strings containing signs # among them.

    PHP can handle # in a string without problems. The error that you are
    manufacturing must pass # by a query string. In a URL, # indicates a
    element named inside the page. To use # as a character who is preserved
    as a literal value, you need to urlencode. You can either do
    with the urlencoded function. It is probably easier to use the
    URL directly: %23 represents #.

    --
    Adobe Community Expert David Powers
    Author, "The Essential Guide to Dreamweaver CS3" (friends of ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • Example to use the query string in the Oracle Access Manager policy.

    Hi all

    Can is there any one please tell me what is the value of the query string and Query String Variable OAM political?

    If possible, please explain with an example of the sample.

    Thanks in advance.

    Siva NAKI.

    Let's say I have an application that has logout URL as http://abc.com/app.cgi?function=logout&user=LOGGED_USER.
    In this case, logged in user will always be different, but you want the user to sign out when this URL is hit. In this scenario, you can use query string variables and specify the function = disconnect it.

    In other scenarios where you know all the query parameters and you want to protect these URLs then the query string can be used.

    Thank you
    Kiran Thakkar

  • You can control a URL in eloqua to add to the query string?

    If I insert a URL in an email, I can't stop eloqua to add additional query string parameters in eloqua.

    I want to make this happen because the URL doesn't seem to work if we add an extra parameter using the query string.

    I had a similar problem recently, and even turn off the tracking doesn't seem to help.  I finally decided to use a shortened URL (bit.ly) and it worked for me.

  • Find and replace the delimited string value by the

    Hi all

    I have a requirement where I need to find and replace the delimited string values.

    For example, the string is "GL ~ 1001 ~ 157747 ~FEB-13~ CREDIT ~ A ~ N ~ US ~ NULL ~". The 4th column gives the month and year. I need to replace it with the name of the previous month. For example: "GL ~ 1001 ~ 157747 ~JAN-13~ CREDIT ~ A ~ N ~ US ~ NULL ~". I need to do the same thing for the past 12 months.

    I thought initially divide the values and store it in a variable and then after him substituting the value required, join the return.

    I just wanted to know if there is a better way to do it?

    Like this:

    with a model like

    (select "GL ~ 1001 ~ 157747 ~ FEB-13 ~ CREDIT ~ A ~ N ~ $ ~ NULL ~' double UNION ALL data")

    Select ' GL ~ 1001 ~ 157747 ~ JAN-13 ~ CREDIT ~ A ~ N ~ US ~ NULL ~' double data)

    Select

    REPLACE (DATA, TO_CHAR (to_date (substr (data, 16.6), "MON-RRRR"), 'MON - RR'), TO_CHAR (to_date (substr (data, 16.6), "MON-RRRR")-1, 'MON - RR'))

    modeling;

    GL ~ 1001 ~ 157747 ~ JAN-13 ~ CREDITS ~ HAS ~ N ~ US ~ NOTHING ~

    GL ~ 1001 ~ 157747 ~ DEC-12 ~ CREDITS ~ HAS ~ N ~ US ~ NOTHING ~

    Ishan

  • Problems with the primary key of the query string

    Moving from asp to php, to work with David Power's book: The Essential Guide to Dreamweaver CS4 with CSS, AJAX, and PHP.  Recycling of my brain, so starting from scratch in the learning process.

    Everything was going perfectly until I tried to add the primary key of a record in a query string.  I compared my code with the example code for the book, and everything matches.  When previewing the page in my browser and hover over the link which must pass the main code on the next page, the query string does not appear correctly.  It shows user_id = but no figure shows, as it is supposed to.  www.webpage.com/update_user.php?user_id=

    Here is my code: (Please note, <>have been removed, as I was unable to find a way view the code in the correct way here (copy/paste was doesn't work do not, nor insert syntax))

    ? PHP {?}

    ? PHP echo $row_listUser ['family_name'];? PHP echo $row_listUser ["FirstName"];?

    ? PHP echo $row_listUser ['username'];?       ? PHP echo $row_listUser ["admin_priv"];?

    a href = "update_user.php? user_id =? php echo $row_listUser ['user_id'];?" "Edit / has

    a href = "delete_user.php? user_id =? php echo $row_listUser ['user_id'];?" ' Delete / has

    ? PHP} while ($row_listUser = mysql_fetch_assoc ($listUser));?

    Any ideas that could help me understand why this part does not in particular would be greatly appreciated.  Writing to the database worked perfectly, I see that there are numbers in the database as user_id, and it is defined as my primary key in the configuration database.  Such a simple process that is causing me headaches!

    Thank you

    You have the code to request a copy in your folder:

    $query_listUser = 'SELECT user_id, username, first_name, family_name, admin_priv from users ORDER BY family_name ASC';

    $listUser = mysql_query ($query_listUser, $connSCFDIR) or die (mysql_error ());

    $row_listUser = mysql_fetch_assoc ($listUser);

    $totalRows_listUser = mysql_num_rows ($listUser);

    $query_listUser = 'SELECT username, first_name, family_name, admin_priv from users ORDER BY family_name ASC';

    $listUser = mysql_query ($query_listUser, $connSCFDIR) or die (mysql_error ());

    $row_listUser = mysql_fetch_assoc ($listUser);

    The $listUser table will contain the results of the second query, which does not include the field user_id. delete the redundant code.

  • How to get the query of the region "PL/SQL function body returns the query string"?

    Hello

    is it possible to get the query string from the region of type "PL/SQL function body returns the query string"?

    I can get the definition of the region as a PL/SQL procedure, but I am interested in the returned query. I tried to write something like

    < pre > v_return_query: = «...» » ;
    : P49_QUERY: = v_return_query;
    Return v_return_query; < / pre >

    to save the return on hidden item P49_QUERY string, but it does not work. I get the error message: ERR-1002 cannot find the item for the "P49_QUERY" element ID in the application '4000 '.

    Kind regards
    Przemek

    If you need to make reference to a page element in the block then you can use this type of control to avoid having to use generic column names:

    if apex_application.get_current_flow_sgid(:APP_ID) = apex_application.get_sgid then-- runtime  :P9_SQL := vSQL;else-- design time  null;end if;
    

    But if all you want to do is capture the SQL debugging you can take all the references element in the block and use the insert statement (in a debug table) as I showed earlier.

    Scott

  • Eloqua reporting: what is the difference between 'Link clicks' and 'interactive generated query string value "?

    clicks.png

    Sometimes, I need to look at the link clicks in order to determine what link they clicked and sometimes the value of query string. What is the difference?

    Redirect link is the actual URL that redirects to a specific Web site location.

    Value of query string of clicks is what follows after the "?" in the link. These query strings do not change the location where the user is directed to but is for information purposes.

    If you were to combine interactive generated link and the value of clicks query string, you will get the full link following the user.

    Example: In your screenshot, for the first row in the report, the user would have followed this link:

    https://play.Google.com/store/apps/details?ID=no.osloby.app

    The report broke it into 2 parts: clicks link (https://play.google.com/store/apps/details) and the value of query string of clicks (? id = no.osloby.app).

    You can create custom query strings under configuration > site: query strings. This can be useful if you want to create your own way to mark up and view metrics on clicks for links. When you define a query string parameter, you can add this setting with different values at the end of the links to follow only those (ex: "?") QueryStringParam = value1'). I used this is to differentiate between separate instances of identical links in the same email (ex: a link is a banner image and text) to see who is the most useful and results in the most traffic. You can then view a breakdown of clicks by each query string under Insight > reports and dashboards > site > overview of Query String parameters.

    Hope this helps... Let me know if you have any other questions.

  • Extract the subset of data in the query string

    Hi all

    I am using query strings in Eloqua for some time and found the implementation of them quite simple. I recently ran well across a scenario where it is not set up as a standard string.

    The URL ends up looking like this:

    http://Sub.domain.com/LP=123/?var=AB-business-_-AB-BusinessAB-_-TRK1AB23_hm_comp2-e_abcdefg_s

    The 'TRK1AB23' is the component I want to extract and place in a field.

    When I use the following code, I find myself everything of value, I want to pull all the way to the end of the string. What should I do to this code to retrieve only the characters that I need?

    function getQueryStringParamValue (strQStrParam) {}

    strURL var = document.location.href;

    var strQStrParamValue = "";

    If (strURL.indexOf('?')! = - 1) {}

    strQStrParamValue = strURL.substr (strURL.indexOf('?') + 1);

    If (strQStrParamValue.indexOf (strQStrParam)! = - 1) {}

    strQStrParamValue = strQStrParamValue.substr (strQStrParamValue.indexOf (strQStrParam));

    strQStrParamValue = strQStrParamValue.substr (strQStrParamValue.indexOf ('TRK') + 1);

    If (strQStrParamValue.indexOf('&')! = - 1) strQStrParamValue = strQStrParamValue.substr (0, strQStrParamValue.indexOf ('&'));

    Return strQStrParamValue;

    } else {}

    strQStrParamValue = defaultHiddenFieldNameValue;

    Return strQStrParamValue;

    }

    } else {}

    strQStrParamValue = defaultHiddenFieldNameValue;

    Return strQStrParamValue;

    }

    }

    Insert here the name of the form

    var form = 'generic ';

    function setCampaign() {}

    var elqForm = return [form];

    Repeat for each field to be completed

    elqForm.elements ['singleLineText'] .value = getQueryStringParamValue ('var');

    }

    Window.OnLoad = setCampaign;

    < /script >

    Egan,

    Your answer actually has helped me tremendously. I learned to look closer the code and found that it was an option of substring. I changed the substring to look at the first three characters of the code (which are always consistent) and then adjusted to shoot only the eight characters containing the code.

    It is not the prettiest or most appropriate code but it does exactly what I need to!

  • Save the alphanumeric string value

    Hello!
    How to save a value to a variable so that I can use it in the future? I have a string of output of a case structure proposed by an OK botton. I want to save the string value when I press the ok botton...
    Thanks in advance
    GM

    Just write the string in a text file.  When you want to use it later, to read the text file.

  • Could not save the different string value to each element of the array

    I have a configuration of VI to read several channels Veristand project.  The entrance is a table 1 d of channels, (an element for each channel, I want to read).  The channels have different names, each of the elements in the chain must be different.  I am able to edit each item and run the VI, and it works fine.  However, if I save, close and reopen the VI, all elements show the same value (what happens to the value of the last element for which I defined a default value).  Is this behavior planned, or have I missed a configuration setting which would allow different string values?  Please notify.  Thank you.

    GSinMN

    Make sure that you select the table and not only one item when you right click-> set by default on the front panel.

  • Bug: APEX_COLLECTION. CREATE_COLLECTION_FROM_QUERY_B change the query string

    Hi APEX Dev Team.

    I found a bug (or I don't know how to get around unexpected behavior) in APEX_COLLECTION. CREATE_COLLECTION_FROM_QUERY_B. I think that it also applies to the CREATE_COLLECTION_FROM_QUERY.

    What's happening: some strings are replaced in the query, I pass into the function. for example '22% ' is replaced by a white. It is not good if I have a query like this:
    SELECT MYCOLA, MYCOLB, MYCOLC FROM MYTABLEA WHERE MYPHONE LIKE '%22306%';
    This returns no rows in the collection. If I run this query in SQL Developer she returns 5 rows.

    When I change the declaration subsequently, it returns 5 rows in the collection.
    SELECT MYCOLA, MYCOLB, MYCOLC FROM MYTABLEA WHERE MYPHONE LIKE '%2306%';
    Trace shows me, the first SELECT statement is replaced by
    SELECT MYCOLA, MYCOLB, MYCOLC FROM MYTABLEA WHERE MYPHONE LIKE ' 306%';
    Which is obviously false :-)

    The changes seem to be limited to 22%, I found no other characters encoding URLS that are replaced in the query.

    Please fix, as I can't find any workaround.

    Thank you
    Peter

    -----
    Blog: http://www.oracle-and-apex.com
    ApexLib: http://apexlib.oracleapex.info
    BuilderPlugin: http://builderplugin.oracleapex.info
    Work: http://www.click-click.at

    Hi Peter,.

    Thanks for reporting this. This seems to be a legacy logic which is no longer necessary (the logic to replace the string '22% '). I corrected it to Application Express 4.1.

    To work around the problem, you can concatenate this string in your application, allowing you to avoid this logic. For example,.

    SELECT MYCOLA, MYCOLB, MYCOLC FROM MYTABLEA WHERE MYPHONE LIKE '%2 '. 2306 ' %';

    Thanks again.

    Joel

  • What is the limit on the query string / post / URL parameters?

    Is there a limitation on the url parameters sent in the post method?

    Thanks in advance.

    Chandra, I'm afraid that I don't know what you just said.

    URL parameters, as far as I know, are not encrypted even in an HTTPS Exchange, because they are considered as part of the URL, only not part of the message.  The body of the message (i.e. POST), on the other hand, it's protected.

    I suggest that you send the query parameters in JSON format, just as you could do it with AJAX.  It is a well designed and well understood Protocol with good support on the client and server side.  (XML is also the same.)  This will put the exchange of information in the body of the message (encrypted), and it also will allow you to send and receive information structured structs and lists and tables and so - on.

    You still need to be aware of the size of the messages, but not nearly as much with the URL string.

    Whenever you feel that you could be "pushing a limit", it is time to think that "there must be a better way to do it."

  • Need help with the query string manipulation

    Hello

    With the help of 10.1.0.4.2

    Given a table called PREFIX_CODES that contains a column called PREFIX_CODE
    with the following data:

    PREFIX_CODE - VARCHAR2 (20)
    -------------------
    AAA
    BENAMER
    CARTER

    and another table called SUBSCRIBERS with a column called SUBSCRIBER_ID
    with the following data:

    SUBSCRIBER_ID - VARCHAR2 (30)
    ---------------------
    BBBB-123456
    AAA-444444
    DD-2222222
    EEEE-888888

    Is there a query that will pull all the SUBSCRIBER_ID that begin with
    each of the PREFIX_CODES? The following query is not valid, but it
    This will give you an idea of what I'm trying to do:

    SELECT SUBSCRIBER_ID
    SUBSCRIBERS
    WHERE AS SUBSCRIBER_ID (SELECT PREFIX_CODE |) » %'
    OF PREFIX_CODES)

    Using the data from above, I would like that the query to return:

    BBBB-123456
    AAA-444444

    Thanks for your help!

    Hello

    Welcome to the forum!

    You were on the right track. To find if a given subscriber corresponds to any prefix_code, you can do an EXISTS subquery:

    SELECT     subscriber_id
    FROM     subsribers     s
    WHERE     EXISTS ( SELECT  NULL
                      FROM      prefix_codes
               WHERE      s.subscriber_id     LIKE prefix_code || '%'
                )
    ;
    

    This will tell you if at least a prefix code. It won't tell you exactly how many, or what they were.
    Your message, I'm guessing that there may be more than one, and you can deduct the subscriber_id itself, then the above query should work for you.

Maybe you are looking for