sequel_pg 1.0.2-x86-mingw32 → 1.1.0-x86-mingw32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.rdoc +5 -0
- data/ext/sequel_pg/sequel_pg.c +11 -3
- data/lib/1.8/sequel_pg.so +0 -0
- data/lib/1.9/sequel_pg.so +0 -0
- metadata +6 -6
data/README.rdoc
CHANGED
@@ -131,6 +131,11 @@ above, please test and send me a report including:
|
|
131
131
|
sequel_pg does it's own timestamp conversions. The :local and :utc
|
132
132
|
settings for database_timestamp and application_timestamp do work,
|
133
133
|
as does setting the datetime_class to DateTime.
|
134
|
+
* You do not need to require the library, the sequel postgres adapter
|
135
|
+
will require it automatically. If you are using bundler, you
|
136
|
+
should add it to your Gemfile like so:
|
137
|
+
|
138
|
+
gem 'sequel_pg', :require=>'sequel'
|
134
139
|
|
135
140
|
== Author
|
136
141
|
|
data/ext/sequel_pg/sequel_pg.c
CHANGED
@@ -23,7 +23,6 @@
|
|
23
23
|
#define SPG_APP_UTC 8
|
24
24
|
|
25
25
|
static VALUE spg_Sequel;
|
26
|
-
static VALUE spg_PG_TYPES;
|
27
26
|
static VALUE spg_Blob;
|
28
27
|
static VALUE spg_BigDecimal;
|
29
28
|
static VALUE spg_Date;
|
@@ -49,6 +48,9 @@ static ID spg_id_new_offset;
|
|
49
48
|
static ID spg_id_call;
|
50
49
|
static ID spg_id_get;
|
51
50
|
|
51
|
+
static ID spg_id_db;
|
52
|
+
static ID spg_id_conversion_procs;
|
53
|
+
|
52
54
|
static ID spg_id_columns;
|
53
55
|
static ID spg_id_encoding;
|
54
56
|
|
@@ -242,6 +244,7 @@ static VALUE spg_yield_hash_rows(VALUE self, VALUE rres, VALUE ignore) {
|
|
242
244
|
VALUE h, rv;
|
243
245
|
size_t l;
|
244
246
|
char * v;
|
247
|
+
VALUE conv_procs = NULL;
|
245
248
|
|
246
249
|
#ifdef SPG_ENCODING
|
247
250
|
int enc_index;
|
@@ -281,7 +284,10 @@ static VALUE spg_yield_hash_rows(VALUE self, VALUE rres, VALUE ignore) {
|
|
281
284
|
colconvert[j] = Qnil;
|
282
285
|
break;
|
283
286
|
default:
|
284
|
-
|
287
|
+
if (conv_procs == NULL) {
|
288
|
+
conv_procs = rb_funcall(rb_funcall(self, spg_id_db, 0), spg_id_conversion_procs, 0);
|
289
|
+
}
|
290
|
+
colconvert[j] = rb_funcall(conv_procs, spg_id_get, 1, INT2NUM(i));
|
285
291
|
break;
|
286
292
|
}
|
287
293
|
}
|
@@ -378,6 +384,9 @@ void Init_sequel_pg(void) {
|
|
378
384
|
spg_id_call = rb_intern("call");
|
379
385
|
spg_id_get = rb_intern("[]");
|
380
386
|
|
387
|
+
spg_id_db = rb_intern("db");
|
388
|
+
spg_id_conversion_procs = rb_intern("conversion_procs");
|
389
|
+
|
381
390
|
spg_id_columns = rb_intern("@columns");
|
382
391
|
spg_id_encoding = rb_intern("@encoding");
|
383
392
|
|
@@ -389,7 +398,6 @@ void Init_sequel_pg(void) {
|
|
389
398
|
spg_BigDecimal = rb_funcall(rb_cObject, cg, 1, rb_str_new2("BigDecimal"));
|
390
399
|
spg_Date = rb_funcall(rb_cObject, cg, 1, rb_str_new2("Date"));
|
391
400
|
spg_Postgres = rb_funcall(spg_Sequel, cg, 1, rb_str_new2("Postgres"));
|
392
|
-
spg_PG_TYPES = rb_funcall(spg_Postgres, cg, 1, rb_str_new2("PG_TYPES"));
|
393
401
|
|
394
402
|
rb_global_variable(&spg_Sequel);
|
395
403
|
rb_global_variable(&spg_Blob);
|
data/lib/1.8/sequel_pg.so
CHANGED
Binary file
|
data/lib/1.9/sequel_pg.so
CHANGED
Binary file
|
metadata
CHANGED
@@ -5,9 +5,9 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 1
|
8
|
+
- 1
|
8
9
|
- 0
|
9
|
-
|
10
|
-
version: 1.0.2
|
10
|
+
version: 1.1.0
|
11
11
|
platform: x86-mingw32
|
12
12
|
authors:
|
13
13
|
- Jeremy Evans
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-
|
18
|
+
date: 2011-05-18 00:00:00 -07:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -42,12 +42,12 @@ dependencies:
|
|
42
42
|
requirements:
|
43
43
|
- - ">="
|
44
44
|
- !ruby/object:Gem::Version
|
45
|
-
hash:
|
45
|
+
hash: 103
|
46
46
|
segments:
|
47
47
|
- 3
|
48
|
-
-
|
48
|
+
- 24
|
49
49
|
- 0
|
50
|
-
version: 3.
|
50
|
+
version: 3.24.0
|
51
51
|
type: :runtime
|
52
52
|
version_requirements: *id002
|
53
53
|
description: |
|