Re: Initializing JsonbValue from cstring

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Igor Stassiy <istassiy(at)gmail(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Initializing JsonbValue from cstring
Date: 2015-02-13 10:52:39
Message-ID: CAFj8pRCeGL7q_EGTz2=FyQZ2Qrtn1x_76mz3fuR=b7beEug7Wg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi

you can call "input function" - jsonb_in

Jsonb *targetjsonbvar = DatumGetJsonb(DirectFunctionCall1(json_in,
CStringGetDatum(cstrvalue)));

Regards

Pavel Stehule

2015-02-13 11:32 GMT+01:00 Igor Stassiy <istassiy(at)gmail(dot)com>:

> Hi,
>
> Is there a way to initialize JsonbValue from cstring from public c api in
> postgres 9.4? Without the use of functions declared with PG_FUNCTION_ARGS
> <http://doxygen.postgresql.org/fmgr_8h.html#adf4dec9b7d23f1b4c68477affde8b7ff>
> .
>
> I posted the following question earlier, but received no reply. Please have
> a look:
>
> "postgresql jsonb processing with c api
> <http://www.postgresql.org/message-id/CAKVOjex6wtQmVFZSMX5vWHgFc3YymPp2dQNkCpPCbaUk+1pOUg@mail.gmail.com>
> "
>
>
> http://www.postgresql.org/message-id/CAKVOjex6wtQmVFZSMX5vWHgFc3YymPp2dQNkCpPCbaUk+1pOUg@mail.gmail.com
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Saimon Lim 2015-02-13 11:17:11 Re: How to hide stored procedure's bodies from specific user
Previous Message Igor Stassiy 2015-02-13 10:32:44 Initializing JsonbValue from cstring