Skip to content Skip to sidebar Skip to footer
Showing posts with the label Regex

Sql/regex Challenge/puzzle: How To Remove Comments From Sql Code (by Using Sql Query)?

Requirements Single-lines comments (e.g. -- my comment) should be removed. Multi-line comments (e.… Read more Sql/regex Challenge/puzzle: How To Remove Comments From Sql Code (by Using Sql Query)?

How Do I Extract Selected Columns Given An Oracle Sql String?

OK, this might seem too tough to be posted here so I beg your pardon. Been working on this for almo… Read more How Do I Extract Selected Columns Given An Oracle Sql String?

Oracle Get All Matched Occurrences From A Column

I have a table, which has 2 columns: ID & JOB_Description(Text). I would like to write an oracl… Read more Oracle Get All Matched Occurrences From A Column

Extract Email Address From String Using Tsql

I'm trying to extract email addresses from an existing comments field and put it into its own c… Read more Extract Email Address From String Using Tsql

Bigquery - Regex To Match Number Of 8 Digits After A Known String

I need to extract 8 digits after a known string: | MyString | Extract: | | ---… Read more Bigquery - Regex To Match Number Of 8 Digits After A Known String

Why Won't This Regex Work In Postgresql

I'm trying to get a regex to capture the base URL from a URL string. This ^(.+?[^\/:])(?=[?\/]|… Read more Why Won't This Regex Work In Postgresql

How To Select Column Names And Tables Of An Sql Using Regex?

I have an SQL string that looks something like this: SELECT USER.'ID', USER.'NAME&#… Read more How To Select Column Names And Tables Of An Sql Using Regex?

Mysql Regexp To Match The Whole Word Only

How can I match the whole word in mysql? For instance, if I type in 'lau', I don't want… Read more Mysql Regexp To Match The Whole Word Only

Sql Server 2008 Regex Clr Use

OK, I realize that SS 2008 doesn't have native regex functions. I also see that it's possib… Read more Sql Server 2008 Regex Clr Use

What Is The Equivalent Of Regexp_substr In Mysql?

I want to extract a word from a string column of a table. description =========================== a… Read more What Is The Equivalent Of Regexp_substr In Mysql?

How To Change The Format Of All Dates In Xml?

I have an xml in a cell in SQL, like: Table: Solution 1: Try this please. declare @I int decl… Read more How To Change The Format Of All Dates In Xml?

Sql Server 2016 How To Use A Simple Regular Expression In T-sql?

I have a column with the name of a person in the following format: 'LAST NAME, FIRST NAME' … Read more Sql Server 2016 How To Use A Simple Regular Expression In T-sql?

Redshift Extract String Between Two Patterns (regexp_substr)

I'm trying to extract the text following deviceSerialNumber= that occurs until either a & o… Read more Redshift Extract String Between Two Patterns (regexp_substr)

Handling Different Escaping Sequences?

I'm using ANTLR with Presto grammar in order to parse SQL queries. This is the original string … Read more Handling Different Escaping Sequences?

Regular Expression To Return Number After Matched String In Oracle

I have a query: select ITEM_ID from system_items where id=4020; I want a regular expression that t… Read more Regular Expression To Return Number After Matched String In Oracle

Sql Regular Expression To Split A Column (string) To Multiple Rows Based On Delimiter '/n'

I have to split a column to multiple rows. The column stores string, and we have to split delimiter… Read more Sql Regular Expression To Split A Column (string) To Multiple Rows Based On Delimiter '/n'

Looking For Phone Number Containing A Minus, Like "123-456789"

I have the following problem. SELECT .... FROM .... WHERE 'Phonenumber' LIKE '1234567… Read more Looking For Phone Number Containing A Minus, Like "123-456789"

Extract Float From String/text Sql Server

I have a Data field that is supposed to have floating values(prices), however, the DB designers hav… Read more Extract Float From String/text Sql Server

Snowflake Sql Regex ~ Extracting Multiple Vals

I am trying to identify a value that is nested in a string using Snowflakes regexp_substr() The val… Read more Snowflake Sql Regex ~ Extracting Multiple Vals

How To Define A Regular Expression With Multiple Or Operators Where Each Term Includes A Space Prefix And Suffix?

I am preparing for a data extraction task. I need to remove a set of terms; none, some or all may b… Read more How To Define A Regular Expression With Multiple Or Operators Where Each Term Includes A Space Prefix And Suffix?