How can I select from a typed set in Oracle 10g?
I.E. SELECT * FROM (3,5,20,68,54,13,56,899,1)
Additionally, how would I filter it?
I.E. SELECT * FROM (3,5,20,68,54,13,56,899,1) WHERE > 5
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Where is the data coming from and what are you planning on doing with it?
If the data is being read from a file, you would normally create an external table to read from the file or use SQL*Loader or some other ETL tool to load the data into a staging table or a PL/SQL collection that you could then query
If you’re doing some sort of manual process, you would normally be looking for data from another table, i.e.
If you’re really trying to generate a data set full of arbitrary data pulled from a file that you don’t want to use Oracle to read, you can always do a series of
SELECTstatements fromDUALthat are allUNION ALL‘d together but this obviously gets rather cumbersome.Additionally, using the WITH clause and a CSV string we can parse a string as a table.
Example: