Re: ECPG bug: "unterminated quoted identifier"

From: 1250kv <1250kv(at)gmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: ECPG bug: "unterminated quoted identifier"
Date: 2020-10-20 18:05:18
Message-ID: CA+4qtLcMz19fc_8UreE+k1uM_-Zh-GOV3_r2vTvJHn7uPaeL6A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

I have expected that host-variable bar the variable will be assigned the
value 'aaa"bbb'
similarly if this value were obtained from a query:

#include <stdio.h>
int main()
{
EXEC SQL char *foo;
foo = (char *) malloc(5);

EXEC SQL SELECT 'aaa"bbb' INTO :foo;

printf("%s\n", foo);
return 0;
}

Result:
aaa"bbb

On Tue, Oct 20, 2020 at 7:57 PM David G. Johnston <
david(dot)g(dot)johnston(at)gmail(dot)com> wrote:

> On Tue, Oct 20, 2020 at 9:47 AM 1250kv <1250kv(at)gmail(dot)com> wrote:
>
>> Hello
>> I have code:
>>
>> void main()
>> {
>> char *foo = "aaa\"bbb";
>> EXEC SQL char *bar = "aaa\"bbb";
>> }
>>
>> ecpg --version
>> ecpg (PostgreSQL) 13.0 (Ubuntu 13.0-1.pgdg20.04+1)
>>
>> ecpg sample.pgc -o 1.c
>> sample .pgc:10: ERROR: unterminated quoted identifier
>>
>
> General usage questions regarding PostgreSQL and ECPG should be sent to
> the -general list.
>
> What are you expecting to be the result of that?
>
> David J.
>
>

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message 1250kv 2020-10-20 18:18:04 Re: ECPG bug: "unterminated quoted identifier"
Previous Message 1250kv 2020-10-20 17:38:46 Re: ECPG bug: PRAPARE FOR