Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5 - Mailing list pgsql-general

From Patrick B
Subject Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5
Date
Msg-id CAJNY3iuDzuKYgeK3zbuALH2vD2HRdWyUbjQw9U9B3PfPPxJV4g@mail.gmail.com
Whole thread Raw
In response to Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5
List pgsql-general
1. Why when I run the function manually I get this error?

        select logextract(201612015, 201612015);

        ERROR:  operator does not exist: timestamp without time zone >=
        integer

        LINE 13:                 BETWEEN

The answer is above. Look at your original query at the top of the post.



 I presume this is wrong: _CREATE or REPLACE FUNCTION
logextract(date_start integer, date_end integer) _- But what should I
use instead?




You mean the error would be: 
select logextract(201612015, 201612015);
 
When it was supposed to be: select logextract(201611015, 201612015);???

This is not the cause, because it was a mistake when I typed the email.
Even doing:

select logextract(20161115,20161215);


I get same error.

pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5
Next
From: "David G. Johnston"
Date:
Subject: Re: [GENERAL] Plpgsql - Custom fields Postgres 9.5