A question on systable_beginscan()

From: Onder Kalaci <onder(at)citusdata(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: A question on systable_beginscan()
Date: 2016-03-25 14:49:02
Message-ID: CAKRSrggiSyCMiQ92RMyF+RmsGOHcsmqN7W3h5z52gJ=_7Bo9dw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi hackers,

As it's documented in the source code, systable_beginscan() could be used
to on non-system tables as well. My question is that, is it possible to
write a C code with systable_beginscan(), systable_getnext() and ScanKeys
which is equivalent to the following query: (Assume that the qual_column is
a text column)

SELECT id FROM table WHERE qual_column::int = 15;

In other words, can we cast a column type to another type via these
low-level APIs? Are there any examples in the Postgres source?

Thanks,
Onder

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David Steele 2016-03-25 15:13:26 Re: POC, WIP: OR-clause support for indexes
Previous Message Alexander Korotkov 2016-03-25 14:39:46 Re: Move PinBuffer and UnpinBuffer to atomics