{"id":1766,"date":"2015-07-24T11:27:08","date_gmt":"2015-07-24T09:27:08","guid":{"rendered":"http:\/\/www.switchbl8.nl\/blog\/?p=1766"},"modified":"2015-07-24T11:27:08","modified_gmt":"2015-07-24T09:27:08","slug":"lists-as-tables-in-oracle","status":"publish","type":"post","link":"https:\/\/www.switchbl8.nl\/blog\/2015\/07\/lists-as-tables-in-oracle\/","title":{"rendered":"Lists as tables in Oracle"},"content":{"rendered":"<p>While searching for a way to find records in a table that best match what I&#8217;m looking for, I just discovered (<a href=\"http:\/\/www.giyf.com\/\">Google is your friend<\/a>) Oracle&#8217;s sys.odcinumberlist and sys.odcivarchar2list. Very nice functions to create in-memory tables.<\/p>\n<p><code>SQL> select * from table(sys.odcivarchar2list('a',null,'b','c'));<\/p>\n<p>COLUMN_VALUE<br \/>\n--------------<br \/>\na<\/p>\n<p>b<br \/>\nc<\/code><\/p>\n<p>Never too old to learn new tricks&#8230;.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>While searching for a way to find records in a table that best match what I&#8217;m looking for, I just discovered (Google is your friend) Oracle&#8217;s sys.odcinumberlist and sys.odcivarchar2list. Very nice functions to create in-memory tables. SQL> select * from table(sys.odcivarchar2list(&#8216;a&#8217;,null,&#8217;b&#8217;,&#8217;c&#8217;)); COLUMN_VALUE &#8212;&#8212;&#8212;&#8212;&#8211; a b c Never too old to learn new tricks&#8230;.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[132],"class_list":["post-1766","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-oracle","category-1-id","post-seq-1","post-parity-odd","meta-position-corners","fix"],"_links":{"self":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/1766","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/comments?post=1766"}],"version-history":[{"count":2,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/1766\/revisions"}],"predecessor-version":[{"id":1768,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/1766\/revisions\/1768"}],"wp:attachment":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/media?parent=1766"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/categories?post=1766"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/tags?post=1766"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}