Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
PostgreSQL Array Support
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  12 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Jeremy Evans  
View profile  
 More options Mar 6 2012, 4:55 pm
From: Jeremy Evans <jeremyeva...@gmail.com>
Date: Tue, 6 Mar 2012 13:55:10 -0800 (PST)
Local: Tues, Mar 6 2012 4:55 pm
Subject: PostgreSQL Array Support

I've added a pg_array extension to Sequel with pretty decent support for
PostgreSQL string/numeric arrays:
https://github.com/jeremyevans/sequel/commit/dc25a56e342cde055bac9da2...

There is still a bit more work necessary to easily use PostgreSQL arrays
with models, but this at least makes it easy for datasets.  Unlike the
sequel_column_type_array extension, this supports more types of arrays, as
well as multi-dimensional arrays.  As far as I know, it's the only ruby
parser that supports multi-dimensional string arrays.  The string array
parser is probably fairly slow, I may add a ragel-based parser to sequel_pg
later if people are finding it to be a bottleneck (send ruby-prof output
with your request).

Anyway, if you are a PostgreSQL array user, please give this new extension
a shot.  I'll be expanding on it to make it work nicely with models, and
probably add another extension that makes it possible to use array
operators without dropping to literal SQL.

Thanks,
Jeremy


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter van Hardenberg  
View profile  
 More options Mar 7 2012, 3:29 am
From: Peter van Hardenberg <p...@pvh.ca>
Date: Wed, 7 Mar 2012 00:29:57 -0800
Local: Wed, Mar 7 2012 3:29 am
Subject: Re: PostgreSQL Array Support

fantastic! now that hstore is a proper extension in 9.1, i'd love to
revisit the work i did on that and get it merged in. i'll try and make
some time on thursday to talk.

-p

--
Peter van Hardenberg
San Francisco, California
"Everything was beautiful, and nothing hurt." -- Kurt Vonnegut


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Florian Aßmann  
View profile  
 More options Mar 7 2012, 4:19 am
From: "Florian Aßmann" <florian.assm...@email.de>
Date: Wed, 7 Mar 2012 10:19:17 +0100 (CET)
Local: Wed, Mar 7 2012 4:19 am
Subject: Re: PostgreSQL Array Support
Yeah - that's great news! Thanks for your hard work!


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Franēois Beausoleil  
View profile  
 More options Mar 7 2012, 10:04 am
From: Franēois Beausoleil <francois.beausol...@gmail.com>
Date: Wed, 7 Mar 2012 10:04:15 -0500
Local: Wed, Mar 7 2012 10:04 am
Subject: Re: PostgreSQL Array Support
Oh cool! I was writing array values manually as literals, and also parsing them out manually from the string. I only store ints or floats in my arrays for now.

Thank you very much for your hard work!
Franēois

Franēois Beausoleil
http://blog.teksol.info/

Le mercredi 7 mars 2012 ą 04:19, "Florian Aßmann" a écrit :


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Evans  
View profile  
 More options Mar 7 2012, 1:04 pm
From: Jeremy Evans <jeremyeva...@gmail.com>
Date: Wed, 7 Mar 2012 10:04:12 -0800 (PST)
Local: Wed, Mar 7 2012 1:04 pm
Subject: Re: PostgreSQL Array Support

On Wednesday, March 7, 2012 12:29:57 AM UTC-8, Peter van Hardenberg wrote:
> fantastic! now that hstore is a proper extension in 9.1, i'd love to
> revisit the work i did on that and get it merged in. i'll try and make
> some time on thursday to talk.

That's actually next on my list after I finish up the array support. :)  
Let's talk tomorrow and get the details worked out.  When I looked over
sequel-hstore last night, there were just a few significant changes I was
considering:

* Hash keys should be strings, not symbols
* HStore should be a DelegateClass of Hash, not a subclass
* Make Hstore#[]= convert input key and value to strings before storing
* Consider using the default proc of {|h,k| h[k.to_s]} for the hash so that
you can access values with symbols even though they are stored as strings
* Refactor the parsing somewhat

Thanks,
Jeremy


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter van Hardenberg  
View profile  
 More options Mar 7 2012, 1:07 pm
From: Peter van Hardenberg <p...@pvh.ca>
Date: Wed, 7 Mar 2012 10:07:20 -0800
Local: Wed, Mar 7 2012 1:07 pm
Subject: Re: PostgreSQL Array Support

On Wed, Mar 7, 2012 at 10:04 AM, Jeremy Evans <jeremyeva...@gmail.com> wrote:
> On Wednesday, March 7, 2012 12:29:57 AM UTC-8, Peter van Hardenberg wrote:

> * Hash keys should be strings, not symbols

agreed

> * HStore should be a DelegateClass of Hash, not a subclass

agreed

> * Make Hstore#[]= convert input key and value to strings before storing

i'm iffy on this...

> * Consider using the default proc of {|h,k| h[k.to_s]} for the hash so that
> you can access values with symbols even though they are stored as strings

... but if this is done i'm less concerned.

> * Refactor the parsing somewhat

glad to help here

--
Peter van Hardenberg
San Francisco, California
"Everything was beautiful, and nothing hurt." -- Kurt Vonnegut


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tyler Kellen  
View profile  
 More options Mar 6 2012, 6:52 pm
From: Tyler Kellen <ty...@sleekcode.net>
Date: Tue, 6 Mar 2012 15:52:04 -0800 (PST)
Local: Tues, Mar 6 2012 6:52 pm
Subject: Re: PostgreSQL Array Support
Thank you Jeremy!

On Mar 6, 3:55 pm, Jeremy Evans <jeremyeva...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Evans  
View profile  
 More options Mar 8 2012, 2:09 pm
From: Jeremy Evans <jeremyeva...@gmail.com>
Date: Thu, 8 Mar 2012 11:09:59 -0800 (PST)
Local: Thurs, Mar 8 2012 2:09 pm
Subject: Re: PostgreSQL Array Support

The support for models was committed yesterday
(https://github.com/jeremyevans/sequel/commit/02a3f8366963a62628008331...),
and I just committed the other extension for using array
operators/functions
(https://github.com/jeremyevans/sequel/commit/5494bcd0585048f3e789b6bf...).

Thanks,
Jeremy


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Evans  
View profile  
 More options Mar 12 2012, 6:28 pm
From: Jeremy Evans <jeremyeva...@gmail.com>
Date: Mon, 12 Mar 2012 15:28:57 -0700 (PDT)
Local: Mon, Mar 12 2012 6:28 pm
Subject: Re: PostgreSQL Array Support

On Wednesday, March 7, 2012 10:04:12 AM UTC-8, Jeremy Evans wrote:

> On Wednesday, March 7, 2012 12:29:57 AM UTC-8, Peter van Hardenberg wrote:

>> fantastic! now that hstore is a proper extension in 9.1, i'd love to
>> revisit the work i did on that and get it merged in. i'll try and make
>> some time on thursday to talk.

> That's actually next on my list after I finish up the array support. :)

pg_hstore extension committed:
https://github.com/jeremyevans/sequel/commit/d3a1b65d143fbd4a69b5984e...

Jeremy


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter van Hardenberg  
View profile  
 More options Mar 12 2012, 6:42 pm
From: Peter van Hardenberg <p...@pvh.ca>
Date: Mon, 12 Mar 2012 15:42:51 -0700
Local: Mon, Mar 12 2012 6:42 pm
Subject: Re: PostgreSQL Array Support
woot!

--
Peter van Hardenberg
San Francisco, California
"Everything was beautiful, and nothing hurt." -- Kurt Vonnegut

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Evans  
View profile  
 More options Mar 13 2012, 4:00 pm
From: Jeremy Evans <jeremyeva...@gmail.com>
Date: Tue, 13 Mar 2012 13:00:21 -0700 (PDT)
Local: Tues, Mar 13 2012 4:00 pm
Subject: Re: PostgreSQL Array Support

And pg_hstore_ops for DSL support:
https://github.com/jeremyevans/sequel/commit/683fee9df19bf76b6f894a42...

Jeremy


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter van Hardenberg  
View profile  
 More options Mar 13 2012, 9:06 pm
From: Peter van Hardenberg <p...@pvh.ca>
Date: Tue, 13 Mar 2012 18:06:16 -0700
Local: Tues, Mar 13 2012 9:06 pm
Subject: Re: PostgreSQL Array Support
oooh ooh hstore too!

--
Peter van Hardenberg
San Francisco, California
"Everything was beautiful, and nothing hurt." -- Kurt Vonnegut


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »