pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Erik Wienhold <ewie@ewie.name>
To: jacktby@gmail.com <jacktby@gmail.com>
To: pgsql-general <pgsql-general@lists.postgresql.org>
Subject: Re: How to create a new operator inpg for spec data type?
Date: Wed, 1 Feb 2023 07:37:11 +0100 (CET)
Message-ID: <1793578543.67829.1675233431851@office.mailbox.org> (raw)
In-Reply-To: <202302011340413081513@gmail.com>
References: <202302011340413081513@gmail.com>

> On 01/02/2023 06:40 CET jacktby@gmail.com <jacktby@gmail.com> wrote:
>
> I need to create a new operator like '<->' and its syntax is that text1 <-> text2,
> for the usage like this: 'a' <-> 'b' = 'a1b1', so how could I realize this one?
> Can you give me some exmaples.

https://www.postgresql.org/docs/current/sql-createoperator.html

But why use an operator and not just the function that you must create anyway?

--
Erik





view thread (2+ messages)

Message-ID: <1793578543.67829.1675233431851@office.mailbox.org>
Permalink:  ../1793578543.67829.1675233431851@office.mailbox.org/
Also on:    postgresql.org/message-id/1793578543.67829.1675233431851@office.mailbox.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: ewie@ewie.name, jacktby@gmail.com
  Subject: Re: How to create a new operator inpg for spec data type?
  In-Reply-To: <1793578543.67829.1675233431851@office.mailbox.org>
  References: <202302011340413081513@gmail.com> <1793578543.67829.1675233431851@office.mailbox.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox