Re: Fatal error when not numeric value - PostgreSQL 9.2

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: "drum(dot)lucas(at)gmail(dot)com" <drum(dot)lucas(at)gmail(dot)com>
Cc: Postgres General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Fatal error when not numeric value - PostgreSQL 9.2
Date: 2016-02-03 23:03:28
Message-ID: CAKFQuwbOGc3QAbd8bGRfMK9q77oXAwf9k0O3W48G91=QaAyDcQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Feb 3, 2016 at 3:48 PM, drum(dot)lucas(at)gmail(dot)com <drum(dot)lucas(at)gmail(dot)com>
wrote:

> Hi all,
>
> Below is an example of the auto-generated update query, with
> client-supplied keys (_iid). There's a fatal error when _iid is not
> numeric. However; this should accept any value.
>
> *Question:* How could I do something that would allow _iid to be more
> than just an INT?
>
> WITH
> in_rows AS (
> SELECT
> CAST(customer_id AS BIGINT),
> csv_data,
> freshbooks_id,
> myob_id,
> ppy_id,
> qb_id,
> xero_id,
> _iid
> FROM
> (
> VALUES('3905', E'\x1A', E'\x1A', 'c59894c-142b6', E'\x1A', E'\x1A', E'\x1A', '44'),('39107', E'\x1A', E'\x1A', '6260-2ba1', E'\x1A', E'\x1A', E'\x1A', '65e-0f0d-49b4-9ac1-a8752ba1'),
>
> Thank you
> Lucas
>

​You have a fatal error because the query you provided is malformed. Send
something that works, and provokes the relevant error, and we might be able
to help.

David J.
​

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message drum.lucas@gmail.com 2016-02-03 23:09:41 Re: Fatal error when not numeric value - PostgreSQL 9.2
Previous Message drum.lucas@gmail.com 2016-02-03 22:48:06 Fatal error when not numeric value - PostgreSQL 9.2