MySQL insert() and instr() equiv - Mailing list pgsql-general

From Mark Constable
Subject MySQL insert() and instr() equiv
Date
Msg-id 200606180206.28483.markc@renta.net
Whole thread Raw
Responses Re: MySQL insert() and instr() equiv
Re: MySQL insert() and instr() equiv
List pgsql-general
When using MySQL I have one select that uses MySQL functions so I am
wondering about the best way to go to end up with the same result in
PostgreSQL.

uid is an email address stored in the passwd table as user@domain.com
and this construct allows an incoming username such as "user.domain.com"
to be compared to the stored "user@domain.com".

SELECT wpath FROM passwd WHERE uid="\L" OR insert(uid,instr(uid,'@'),1,'.')="\L"

--markc

pgsql-general by date:

Previous
From: "Greg Quinn"
Date:
Subject: Question about openSSL
Next
From: Tom Lane
Date:
Subject: Re: MySQL insert() and instr() equiv