Обсуждение:

Поиск
Список
Период
Сортировка

От
Ramesh T
Дата:
CREATE AGGREGATE group_concat(text) (
    SFUNC = _group_concat,
    STYPE = text
);
is it availabe in oracle..?

Re:

От
Adrian Klaver
Дата:
On 02/24/2015 10:08 AM, Ramesh T wrote:
> CREATE AGGREGATE group_concat(text) (
>      SFUNC = _group_concat,
>      STYPE = text
> );
> is it availabe in oracle..?

FYI, this is the Postgres list. You might have more success on an Oracle
list.

--
Adrian Klaver
adrian.klaver@aklaver.com


Re: (unknown)

От
Thomas Kellerer
Дата:
Ramesh T schrieb am 24.02.2015 um 19:08:
> CREATE AGGREGATE group_concat(text) (
>     SFUNC = _group_concat,
>     STYPE = text
> );
> is it availabe in oracle..?

https://docs.oracle.com/cd/E11882_01/server.112/e41084/functions089.htm#SQLRF30030

Re:

От
Adrian Klaver
Дата:
On 03/03/2015 04:39 AM, Ramesh T wrote:
> hi all,
>             I am using postgres 9.4 on windows 7.
>
> i want import that backup sql file into postgres schema.
> i googled i got copy, but when i ran in windows
>
> COPY actor FROM 'c:\users\venu\downloads\sakila-data.sql';
>
> ERROR:  invalid input syntax for integer: ""

The problem is above, you can not have an empty string in a integer
field. That is a MySQLism for NULL. There is a version of the Sakila
data files rewritten for Postgres, called Pagila. Unfortunately it is on
PgFoundry (http://pgfoundry.org/projects/dbsamples/) and that site seems
to be dead.  So you have couple of options, sanitize the data files
using some text tools to clean out the empty strings or make the table
field a varchar and clean the data there and then change back to integer.

> CONTEXT:  COPY actor, line 1, column actor_id: ""
> ********** Error **********
>
> the backupdata format
>
> COPY actor (actor_id, first_name, last_name, last_update) FROM stdin;
> 1 PENELOPE GUINESS 2006-02-15 09:34:33
> 2 NICK WAHLBERG 2006-02-15 09:34:33
> 3 ED CHASE 2006-02-15 09:34:33
> 4 JENNIFER DAVIS 2006-02-15 09:34:33
>
>
>
>   how to import to table from file in postgres
> any help..?
>


--
Adrian Klaver
adrian.klaver@aklaver.com