how to use comma separated value list in the where clause oracle

Ads
 

how to use comma separated value list in the where clause oracle

Hi,

how to use comma separated value list in the where clause oracle

Thanks

View Answers

October 10, 2017 at 9:51 PM

HI,

Following code will help you:

select * from employee where id in (
   select regexp_substr('1,2,3,4','[^,]+', 1, level) from dual
   connect by regexp_substr('1,2,3,4', '[^,]+', 1, level) is not null 
   );

Thanks


October 10, 2017 at 9:51 PM

HI,

Following code will help you:

select * from employee where id in (
   select regexp_substr('1,2,3,4','[^,]+', 1, level) from dual
   connect by regexp_substr('1,2,3,4', '[^,]+', 1, level) is not null 
   );

Thanks


October 10, 2017 at 9:52 PM

HI,

Following code will help you:

select * from employee where id in (
   select regexp_substr('1,2,3,4','[^,]+', 1, level) from dual
   connect by regexp_substr('1,2,3,4', '[^,]+', 1, level) is not null 
   );

Thanks

Ads









Related Tutorials/Questions & Answers:
how to use comma separated value list in the where clause oracle
how to use comma separated value list in the where clause oracle  Hi, how to use comma separated value list in the where clause oracle Thanks   HI, Following code will help you: select * from employee where id
HOW CN I USE WHERE AND BETWEEN CLAUSE SIMULTANEOUSLY... IN MYSQL
HOW CN I USE WHERE AND BETWEEN CLAUSE SIMULTANEOUSLY... IN MYSQL  sir, how can i use WHERE and BETWEEN clause simultaneously..? my tables details... WHERE _exp_date BETWEEN ('2009-07-01' AND '2011-07-30') AND _exp_for_id = 1
Advertisements
Explain the use of the ‘LIKE’ keyword used in the WHERE clause?
Explain the use of the ?LIKE? keyword used in the WHERE clause?   Explain the use of the ?LIKE? keyword used in the WHERE clause
Explain the use of the ‘LIKE’ keyword used in the WHERE clause?
Explain the use of the ?LIKE? keyword used in the WHERE clause?   Explain the use of the ?LIKE? keyword used in the WHERE clause
Java arraylist to comma separated string
arrayList is converted into the comma separated string. For this take one.... Example of Java Arraylist Comma Separated String import java.util.ArrayList... ar[]={1,2,3,4};      ArrayList list=new ArrayList();      list.add(ar[0
Hibernate WHERE Clause
Hibernate WHERE Clause In this tutorial you will learn how to use HQL where clause. Use of WHERE clause in hibernate is as same as it used in SQL... a simple java file into which we will use HQL where clause for extracting
JDBC: WHERE Clause Example
JDBC: WHERE Clause Example In this section, we will discuss how to use WHERE...(); } } } Output : Use of WHERE Clause in JDBC... RollNo Name Course.... WHERE Clause : MySql Where Clause is used to write some condition and data
Where clause
Where clause  I have doubt in Where clause .. i got a Employid from...; The WHERE clause is used to filter records.It is used to extract only those..._name(s) FROM table_name WHERE column_name = value; Example: In the given
how to use dropdown list in JSP and display value in same page
how to use dropdown list in JSP and display value in same page  I have a Dropdown list with some values say "A", "B" and "C" When the user selects... in the same page Value selected = C How can we do this in a JSP page
Explain the use of the ?LIKE? keyword used in the WHERE clause? Explain wildcard characters in SQL.
Explain the use of the ?LIKE? keyword used in the WHERE clause? Explain wildcard characters in SQL.  Explain the use of the ?LIKE? keyword used in the WHERE clause? Explain wildcard characters in SQL
Explain the use of the ‘LIKE’ keyword used in the WHERE clause? Explain wildcard characters in SQL.
Explain the use of the ?LIKE? keyword used in the WHERE clause? Explain wildcard characters in SQL.  Explain the use of the ?LIKE? keyword used in the WHERE clause? Explain wildcard characters in SQL
Where Clause in SQL
The Tutorial illustrate an example from where clause in SQL. In this Tutorial we use... Where Clause in SQL       The Where clause in SQL query is used  with the SELECT keyword
Where and Having clause
Where and Having clause   hii, What is the difference between where and having clause?   hello, WHERE clause is used to impose... BY clause. HAVING clause is used to impose condition on GROUP Function
where clause in select statement
where clause in select statement  In Mysql,I write the following query: select * from emp where designation = "MANAGER" But the actual value... nly if the where condition is "manager" and not "MANAGER
Where clause with query in MySQL
Where clause with query in MySQL  Hi, I want to learn the where... is the various example of where clause: Suppose we have following table: mysql> select... (0.00 sec) Following shows more uses of where clause: mysql> select * from
SQL Aggregate Functions In Where Clause
specified in the 'Stu_Name'. In order to overcome, we use the WHERE clause... SQL Aggregate Functions In Where Clause       SQL Aggregate Function In Where Clause return
What is the difference between a HAVING CLAUSE and a WHERE CLAUSE?
What is the difference between a HAVING CLAUSE and a WHERE CLAUSE?  What is the difference between a HAVING CLAUSE and a WHERE CLAUSE?   Hi, Both HAVING and WHERE clause used for specifying the search condition in SQL
PHP SQL Query Where Clause
PHP SQL Query Where Clause       This example illustrates how to create and execute the sql query with where clause. To understand how to display the result returned 
Php Sql Where
Php Sql Where This example illustrates how to use the WHERE clause in the UPDATE query in PHP. In this example we create a UPDATE query with WHERE clause to update the field emp_name where name is 'amar'. In the figure below the first
Mysql Date in where clause
Mysql Date in where clause     ... records from table employee1 on the basis of condition specified in WHERE clause... in Where clause. The given Query create table employee1 is used to create a table
how to set value of dropdown list
how to set value of dropdown list  Hello Sir, I'd solved the earlier problems somehow but now this time another problem arised when I want to pass the value from a link to a dropdown list. I want to set the dropdown list selected
how to set value of dropdown list
how to set value of dropdown list  Hello Sir, I'd solved the earlier problems somehow but now this time another problem arised when I want to pass the value from a link to a dropdown list. I want to set the dropdown list selected
HQL Where Clause Example
HQL Where Clause Example       Where Clause is used to limit the results returned from... lngInsuranceId='1' Where Clause can be used with or without Select Clause. Here
how to create a bar chart in jsp by fetching value from oracle databse?
how to create a bar chart in jsp by fetching value from oracle databse?  i want to show the population of various states in a bar chart in my jsp page by fetching the data from my oracle table. i am using my eclipse as my IDE
How to use Bean Area in Oracle Forms 9i with Sample code ?
How to use Bean Area in Oracle Forms 9i with Sample code ?  Hi friend.I posted a query,but I didn't get the answer for it.Help me to resolve including a bean area in oracle forms 9i and using it in forms.Thanks in advance.Help me
How to use List in velocity
How to use List in velocity       This Example shows you how to use List in velocity. ...;new VelocityContext();   context.put("stuList", list);  
Using WHERE Clause in JDBC
Using WHERE Clause in JDBC    Where... conditions. It allows to filter the data from a table, a WHERE clause can be added to the SELECT statement. The WHERE clause searches the specific results
How to split string in Java using comma?
How to split string in Java using comma?  Hi, Share the example code for splitting the string in Java using comma as separator. Thanks   Hi, You can use the split() function of the String class to split the string
What is the difference between IN and BETWEEN, that are used inside a WHERE clause?
inside a WHERE clause?   Hi, The BETWEEN clause is used to fetch a range of values, whereas the IN clause fetches data from a list of specified values...What is the difference between IN and BETWEEN, that are used inside a WHERE
SQL Aggregate Functions Where Clause
SQL Aggregate Functions Where Clause       SQL Aggregate Functions Where Clause return you the aggregate sum of the records based on the condition specified in Where Clause condition
JPA Query with where clause and group by function
JPA Query with where clause and group by function  Any thing wrong in my JPA Query. TypedQuery<RaBdrRating> uQuery = (TypedQuery<...(charge),COUNT(activePackage) FROM User WHERE callType = :callType and startDate

Ads