Skip to content

Self Join : How to select a specific set of data

I have a simple table with data as As we can see that row 1 & 2 contains exact same ColumnA, ColumnB & ColumnC. I want to form a simple select that can ignore the ‘N’ values where we already …

How to deal with Dynamic Queries

Simple Question I have a table that looks like this I am looking to do is do a select so I can get a result as Is this a PIVOTING issue? looking for suggestions to see how I can form a ‘Select’ …

presto replace multiple characters

I have a string and would like to remove a set of characters. Is there a better way than chaining multiple replace()? I came up with the following but it requires a replace() call for each character: This is a minimal example and I have more characters to escape so I was looking for a less verbose way of achi…

How do I Count the words in a string using regex

I’m trying to count the words in a string using regex in Oracle 10g. I’ve been trying this select * from books where REGEXP_LIKE(title, ‘[ ]{2}’); so that its returning titles with at least 3 words …