Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread pabloa98
Thank you David, I will use list. On Wed, Apr 17, 2019 at 6:42 PM David Rowley wrote: > On Thu, 18 Apr 2019 at 10:19, Adrian Klaver > wrote: > > CREATE TABLE automatic.measurement_automatic PARTITION OF > > automatic.measurement > > test-# FOR VALUES FROM (1) TO (1) > > test-# PARTITION

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread pabloa98
you are right. What it happens is that the batch importing process drops the schema and recreates it. I would like some solution that is compatible with that. I am sure partitioned tables will have an impact but on the other hand, it will solve the problem I have now without touching the legacy co

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread David Rowley
On Thu, 18 Apr 2019 at 10:19, Adrian Klaver wrote: > CREATE TABLE automatic.measurement_automatic PARTITION OF > automatic.measurement > test-# FOR VALUES FROM (1) TO (1) > test-# PARTITION BY RANGE (origin); > ERROR: empty range bound specified for partition "measurement_automatic" > DET

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread David Rowley
On Thu, 18 Apr 2019 at 10:56, Alvaro Herrera wrote: > > Note that unless you regularly query for only-manually-inserted or > only-automatically-inserted data, this will be useless and will make > queries more expensive, with no upside. Going by "Since those rows are inserted by hand, they will be

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread Adrian Klaver
On 4/17/19 3:56 PM, Alvaro Herrera wrote: Note that unless you regularly query for only-manually-inserted or only-automatically-inserted data, this will be useless and will make queries more expensive, with no upside. Well the OP's use case is: "I would like to store in that table manually gen

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread Alvaro Herrera
Note that unless you regularly query for only-manually-inserted or only-automatically-inserted data, this will be useless and will make queries more expensive, with no upside. Generally speaking, it's not a problem to put partitions in different schemas. -- Álvaro Herrerahttps://

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread pabloa98
Thank you! This is exactly was I was looking for. The range thing is good enough for me. Pablo On Wed, Apr 17, 2019 at 3:19 PM Adrian Klaver wrote: > On 4/17/19 2:21 PM, pabloa98 wrote: > > I have a schema with a generated table with information coming from > > batch processes. > > > > I would

Re: is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread Adrian Klaver
On 4/17/19 2:21 PM, pabloa98 wrote: I have a schema with a generated table with information coming from batch processes. I would like to store in that table manually generated information. Since those rows are inserted by hand, they will be lost when the table will be reimported. So I was t

is it possible to create partitioned tables using tables from different schemas

2019-04-17 Thread pabloa98
I have a schema with a generated table with information coming from batch processes. I would like to store in that table manually generated information. Since those rows are inserted by hand, they will be lost when the table will be reimported. So I was thinking of creating a partitioned table wi