Skip site navigation (1) Skip section navigation (2)

DB insert Error

From: "Jasbinder Bali" <jsbali(at)gmail(dot)com>
To: pgsql-novice(at)postgresql(dot)org, pgsql-general(at)postgresql(dot)org
Subject: DB insert Error
Date: 2006-08-16 03:55:58
Message-ID: a47902760608152055i4ecfc682v6f8b6a88901d9202@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-generalpgsql-novice
Hi,
I'm using ECPG and trying to do follwoing insert in one of the talbes.

 insert into raw_email ( id  , raw_email  ) values ( 1 , :ch);

ch is an array and defined as follows:

 EXEC SQL BEGIN DECLARE SECTION;
    char ch[MSG_LEN];
EXEC SQL END DECLARE SECTION;

contents of array ch is actually a parsed raw email that i've attached
herewith.

I get the following error when the insert statement is hit:

[2446]: ECPGexecute line 97: Error: ERROR:  array value must start with "{"
or dimension information.

No clue what this error is all about. I googled for this error, found a few
results but that didn't help much.

Thanks,
~Jas

Attachment: contents.txt
Description: text/plain (1.9 KB)

Responses

pgsql-novice by date

Next:From: Michael FuhrDate: 2006-08-16 04:19:45
Subject: Re: DB insert Error
Previous:From: Jaime CasanovaDate: 2006-08-16 03:28:53
Subject: Re: Return type for procedure

pgsql-general by date

Next:From: Michael FuhrDate: 2006-08-16 04:19:45
Subject: Re: DB insert Error
Previous:From: Michael FuhrDate: 2006-08-16 01:31:31
Subject: Re: Connection string

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group