ruby-oci8 1.0.7-x86-mswin32-60 → 2.0.1-x86-mswin32-60
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +1289 -383
- data/Makefile +48 -12
- data/NEWS +5 -419
- data/README +56 -385
- data/VERSION +1 -1
- data/dist-files +27 -27
- data/lib/.document +2 -0
- data/lib/dbd/OCI8.rb +2 -17
- data/lib/oci8.rb +48 -1622
- data/lib/oci8.rb.in +48 -1622
- data/lib/oci8/.document +5 -0
- data/lib/oci8/compat.rb +108 -0
- data/lib/oci8/datetime.rb +491 -0
- data/lib/oci8/encoding-init.rb +40 -0
- data/lib/oci8/encoding.yml +537 -0
- data/lib/oci8/metadata.rb +2077 -0
- data/lib/oci8/object.rb +548 -0
- data/lib/oci8/oci8.rb +798 -0
- data/lib/oci8/oracle_version.rb +144 -0
- data/lib/oci8lib_18.so +0 -0
- data/lib/oci8lib_191.so +0 -0
- data/metaconfig +3 -3
- data/ruby-oci8.gemspec +24 -15
- data/setup.rb +4 -4
- data/test/config.rb +64 -84
- data/test/test_all.rb +14 -21
- data/test/test_array_dml.rb +333 -0
- data/test/test_bind_raw.rb +18 -25
- data/test/test_bind_time.rb +78 -91
- data/test/test_break.rb +37 -35
- data/test/test_clob.rb +33 -89
- data/test/test_connstr.rb +5 -4
- data/test/test_datetime.rb +469 -0
- data/test/test_dbi.rb +99 -60
- data/test/test_dbi_clob.rb +3 -8
- data/test/test_metadata.rb +65 -51
- data/test/test_oci8.rb +151 -55
- data/test/test_oracle_version.rb +70 -0
- data/test/test_oradate.rb +76 -83
- data/test/test_oranumber.rb +405 -71
- data/test/test_rowid.rb +6 -11
- metadata +21 -25
- data/ext/oci8/oci8lib.so +0 -0
- data/ruby-oci8.spec +0 -62
- data/support/README +0 -4
- data/support/runit/assert.rb +0 -281
- data/support/runit/cui/testrunner.rb +0 -101
- data/support/runit/error.rb +0 -4
- data/support/runit/method_mappable.rb +0 -20
- data/support/runit/robserver.rb +0 -25
- data/support/runit/setuppable.rb +0 -15
- data/support/runit/teardownable.rb +0 -16
- data/support/runit/testcase.rb +0 -113
- data/support/runit/testfailure.rb +0 -25
- data/support/runit/testresult.rb +0 -121
- data/support/runit/testsuite.rb +0 -43
- data/support/runit/version.rb +0 -3
- data/test/test_describe.rb +0 -137
data/Makefile
CHANGED
@@ -1,14 +1,12 @@
|
|
1
1
|
VERSION = `cat VERSION`
|
2
|
-
RUBY = ruby
|
3
|
-
GEM = gem
|
4
|
-
CONFIG_OPT =
|
2
|
+
RUBY = ruby -w
|
5
3
|
|
6
4
|
all: build
|
7
5
|
|
8
6
|
build: config.save setup
|
9
7
|
|
10
8
|
config.save: lib/oci8.rb.in
|
11
|
-
$(RUBY) setup.rb config
|
9
|
+
$(RUBY) setup.rb config
|
12
10
|
|
13
11
|
setup:
|
14
12
|
$(RUBY) setup.rb setup
|
@@ -28,14 +26,16 @@ install:
|
|
28
26
|
site-install:
|
29
27
|
$(RUBY) setup.rb install
|
30
28
|
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
binary_gem: build
|
35
|
-
$(GEM) build ruby-oci8.gemspec -- current
|
29
|
+
format_c_source:
|
30
|
+
astyle --options=none --style=linux --indent=spaces=4 --brackets=linux --suffix=none ext/oci8/*.[ch]
|
36
31
|
|
37
32
|
# internal use only
|
38
|
-
|
33
|
+
.PHONY: rdoc
|
34
|
+
|
35
|
+
rdoc:
|
36
|
+
$(RUBY) custom-rdoc.rb -o rdoc -U README ext/oci8 lib
|
37
|
+
|
38
|
+
dist:
|
39
39
|
-rm -rf ruby-oci8-$(VERSION)
|
40
40
|
mkdir ruby-oci8-$(VERSION)
|
41
41
|
tar cf - `cat dist-files` | (cd ruby-oci8-$(VERSION); tar xf - )
|
@@ -47,5 +47,41 @@ dist-check: dist
|
|
47
47
|
cd ruby-oci8-$(VERSION)/src && $(MAKE) RUBY="$(RUBY)" sitearchdir=../work sitelibdir=../work site-install
|
48
48
|
cd ruby-oci8-$(VERSION)/test && $(RUBY) -I../work -I../support test_all.rb
|
49
49
|
|
50
|
-
|
51
|
-
|
50
|
+
#
|
51
|
+
# for Windows
|
52
|
+
#
|
53
|
+
GEMPKG = ruby-oci8-unstable-2.0.1-x86-mswin32-60.gem
|
54
|
+
|
55
|
+
ext\oci8\oci8lib_18.so:
|
56
|
+
c:\ruby\bin\ruby -r fileutils -e "FileUtils.rm_rf('ruby18')"
|
57
|
+
md ruby18
|
58
|
+
cd ruby18
|
59
|
+
c:\ruby\bin\ruby ..\setup.rb config -- --with-runtime-check
|
60
|
+
c:\ruby\bin\ruby ..\setup.rb setup
|
61
|
+
rem c:\ruby\bin\ruby ..\setup.rb test
|
62
|
+
cd ..
|
63
|
+
copy ruby18\ext\oci8\oci8lib_18.so ext\oci8\oci8lib_18.so
|
64
|
+
|
65
|
+
ext\oci8\oci8lib_191.so:
|
66
|
+
c:\ruby\bin\ruby -r fileutils -e "FileUtils.rm_rf('ruby191')"
|
67
|
+
md ruby191
|
68
|
+
cd ruby191
|
69
|
+
c:\ruby-1.9.1\bin\ruby ..\setup.rb config -- --with-runtime-check
|
70
|
+
c:\ruby-1.9.1\bin\ruby ..\setup.rb setup
|
71
|
+
rem c:\ruby-1.9.1\bin\ruby ..\setup.rb test
|
72
|
+
cd ..
|
73
|
+
copy ruby191\ext\oci8\oci8lib_191.so ext\oci8\oci8lib_191.so
|
74
|
+
copy ruby191\lib\oci8.rb lib\oci8.rb
|
75
|
+
|
76
|
+
$(GEMPKG): ext\oci8\oci8lib_18.so ext\oci8\oci8lib_191.so ruby-oci8.gemspec
|
77
|
+
c:\ruby-1.9.1\bin\gem build ruby-oci8.gemspec -- current
|
78
|
+
|
79
|
+
test-win32-ruby18: $(GEMPKG)
|
80
|
+
c:\ruby\bin\gem install $(GEMPKG) --no-rdoc --no-ri
|
81
|
+
c:\ruby\bin\ruby -rubygems test\test_all.rb
|
82
|
+
|
83
|
+
test-win32-ruby191: $(GEMPKG)
|
84
|
+
c:\ruby-1.9.1\bin\gem install $(GEMPKG) --no-rdoc --no-ri
|
85
|
+
c:\ruby-1.9.1\bin\ruby test\test_all.rb
|
86
|
+
|
87
|
+
test-win32: test-win32-ruby18 test-win32-ruby191
|
data/NEWS
CHANGED
@@ -1,420 +1,6 @@
|
|
1
|
-
|
1
|
+
2.0.1:
|
2
2
|
|
3
|
-
*
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
* fix oraconf.rb for AIX instant clients.
|
8
|
-
(reported by Kazuya Teramoto)
|
9
|
-
|
10
|
-
* fix oraconf.rb for ruby 1.8.5 with Oracle 8.x which needs some object
|
11
|
-
files to link with.
|
12
|
-
(reported by Jayson Cena)
|
13
|
-
|
14
|
-
1.0.6:
|
15
|
-
|
16
|
-
* fix a problem when compiling for Oracle 8.0.
|
17
|
-
(reported by Axel Reinhold as a ruby-oci8 2.0 issue)
|
18
|
-
|
19
|
-
* [dbi] fix to pass a newly added sanity check in dbi 0.4.1.
|
20
|
-
(reported by Dirk Herzhauser as a ruby-oci8 2.0 issue)
|
21
|
-
|
22
|
-
* [dbi] fix dbh#columns for Oracle 8.1 or lower.
|
23
|
-
The data dictionary all_constraints doesn't have index_name
|
24
|
-
column on Oracle 8i. Rewrite DBI::DBD::OCI8::Database#columns
|
25
|
-
by using all_cons_columns.
|
26
|
-
(backport from ruby-oci8 trunk)
|
27
|
-
|
28
|
-
1.0.5:
|
29
|
-
|
30
|
-
No changes except who try to install on Mac OS X ppc.
|
31
|
-
|
32
|
-
- fix big/little endian checking problem on Mac OS X ppc.
|
33
|
-
(contributed by unknown. See: Bug ID 24284 on rubyforge.)
|
34
|
-
|
35
|
-
1.0.4:
|
36
|
-
|
37
|
-
1. [dbi] support ruby-dbi 0.4
|
38
|
-
(Thanks to James Cao and Peter Zingg.)
|
39
|
-
|
40
|
-
Ruby-dbi 0.4 is supported by DBD::OCI8 after 6 months from the
|
41
|
-
release of 0.4.
|
42
|
-
|
43
|
-
If you are using ruby-dbi 0.1.1, you need to copy dbd/OCI8.rb
|
44
|
-
to DBD/OCI8/OCI8.rb. The file itself works fine with ruby-dbi
|
45
|
-
0.1.1, but the dbi cannot find the file by default.
|
46
|
-
|
47
|
-
2. Rowid column data are fetched as a String by default.
|
48
|
-
|
49
|
-
3. The return type of OCI8::Cursor#rowid is changed from OCIRowid
|
50
|
-
to String.
|
51
|
-
|
52
|
-
Note: It needs one network roundtrip to convert OCIRowid to
|
53
|
-
String on server side when using Oracle 8.x client.
|
54
|
-
On Oracle 9.0 or upper it is converted in the client side.
|
55
|
-
|
56
|
-
4. An exception is raised if a connection is used in a process which is
|
57
|
-
different with a process to establish the connection.
|
58
|
-
|
59
|
-
If you encounter an exception "The connection cannot be reused in the
|
60
|
-
forked process," see the following link.
|
61
|
-
|
62
|
-
http://groups.google.com/group/phusion-passenger/browse_thread/thread/b00d4770bc1d00b8
|
63
|
-
|
64
|
-
5. fix for 11.1.0.7.0 instant rpm package.
|
65
|
-
(reported by Luis Parravicini.)
|
66
|
-
|
67
|
-
The directory tree is a bit different with that of 11.1.0.6.0
|
68
|
-
or earlier.
|
69
|
-
|
70
|
-
6. suppress compilation warnings.
|
71
|
-
(contributed by Daniel Berger)
|
72
|
-
|
73
|
-
1.0.3:
|
74
|
-
|
75
|
-
1. add workaround code for a losing character problem when reading CLOB.
|
76
|
-
(reported by Efren Yevale and Thomas Witt and fixed with Thomas Witt's help.)
|
77
|
-
|
78
|
-
The problem is happened at the following condition.
|
79
|
-
|
80
|
-
(a) Oracle client version is 10.2.0.4 or 11.1.0.6.
|
81
|
-
It doesn't happend when using 10.2.0.3 client or lower.
|
82
|
-
It doesn't depend on Oracle server version.
|
83
|
-
|
84
|
-
(b) The character set is a variable-length one.
|
85
|
-
e.g. AL32UTF8
|
86
|
-
|
87
|
-
2. fix a problem when reading BLOB/CLOB over 1GB.
|
88
|
-
(reported by Jonathan Hadders.)
|
89
|
-
|
90
|
-
3. [rails] fix a problem that OraNumber#to_json returns "{}" when using Rails.
|
91
|
-
(reported by Alex Moore)
|
92
|
-
|
93
|
-
Rails add to_json method. But it doesn't know what OraNumber is.
|
94
|
-
OraNumber#to_json is added for Rails.
|
95
|
-
|
96
|
-
4. [dbi] fix a problem when using Oracle 8i and ruby-dbi.
|
97
|
-
(reported by Glauco Magnelli.)
|
98
|
-
|
99
|
-
1.0.2:
|
100
|
-
|
101
|
-
1. add a gemspec file.
|
102
|
-
(Thanks to Jesse Hu)
|
103
|
-
|
104
|
-
To make a pure ruby gems package:
|
105
|
-
gem build ruby-oci8.gemspec
|
106
|
-
|
107
|
-
To make a binary gems package:
|
108
|
-
gem build ruby-oci8.gemspec -- current
|
109
|
-
|
110
|
-
|
111
|
-
2. [BUG FIX] fix a segv bug in gc mark.
|
112
|
-
(Thanks to authorNari)
|
113
|
-
|
114
|
-
1.0.1:
|
115
|
-
|
116
|
-
1. [SPEC CHANGE] OCI8#exec and OCI8::Cursor#exec's return value is changed
|
117
|
-
for statement except select, insert, update and delete statement.
|
118
|
-
|
119
|
-
It had been true. But now it is the number of rows processed for all
|
120
|
-
non-select statements.
|
121
|
-
|
122
|
-
For example:
|
123
|
-
|
124
|
-
# 1.0.0 or before
|
125
|
-
conn = OCI8.new('user/pass')
|
126
|
-
conn.exec('rename FOO_TABLE to BAR_TABLE') # => true
|
127
|
-
|
128
|
-
# 1.0.1
|
129
|
-
conn = OCI8.new('user/pass')
|
130
|
-
conn.exec('rename FOO_TABLE to BAR_TABLE') # => 0
|
131
|
-
|
132
|
-
2. fix a bug that OraDate.new made a core dump on x86_64 linux.
|
133
|
-
(reported by Alun Eyre)
|
134
|
-
|
135
|
-
3. fix OCI8#non_blocking = false problem.
|
136
|
-
Once the connection became non-bocking mode, it could
|
137
|
-
not be reset to blocking mode. Now it can be reset.
|
138
|
-
(reported by Cagdas Gerede)
|
139
|
-
|
140
|
-
4. support cursors in a result set.
|
141
|
-
(contributed by Randy Gordon)
|
142
|
-
|
143
|
-
For example:
|
144
|
-
conn = OCI8.new('ruby/oci8')
|
145
|
-
sql = 'SELECT CURSOR(SELECT * FROM foo where foo.c1 = bar.c1 ) FROM bar'
|
146
|
-
conn.exec(sql) do |row|
|
147
|
-
cursor_in_result_set = row[0]
|
148
|
-
cursor_in_result_set.fetch do |row|
|
149
|
-
puts row.join(',')
|
150
|
-
end
|
151
|
-
end
|
152
|
-
|
153
|
-
5. fix oraconf.rb for official x86_64 linux rpms.
|
154
|
-
(contributed by Pat)
|
155
|
-
|
156
|
-
1.0.0:
|
157
|
-
|
158
|
-
1. fix a BUG when binding a Bignum. This bug was added in
|
159
|
-
ruby-oci8 1.0.0-rc2. (reported by Daniel Berger)
|
160
|
-
|
161
|
-
2. add OCI8#describe_table(table_name), OCI8::Cursor#column_metadata,
|
162
|
-
OCI8::Metadata::Table, OCI8::Metadata::View and OCI8::Metadata::Column.
|
163
|
-
|
164
|
-
table information:
|
165
|
-
con = OCI8.new('username/password')
|
166
|
-
table_info = con.describe_table('table_name') #=> OCI8::Metadata::Table
|
167
|
-
table_info.columns #=> an array of OCI8::Metadata::Column.
|
168
|
-
|
169
|
-
query information:
|
170
|
-
con = OCI8.new('username/password')
|
171
|
-
csr = con.exec('select * from table_name')
|
172
|
-
csr.column_metadata #=> an array of OCI8::Metadata::Column.
|
173
|
-
|
174
|
-
5. add OCI8::BindType::BinaryDouble if oci8lib.so is compiled for
|
175
|
-
Oracle 10g client. You can fetch exactly same values in Oracle.
|
176
|
-
|
177
|
-
You could fetch the values in previous version by adding the
|
178
|
-
following line.
|
179
|
-
|
180
|
-
OCI8::BindType::Mapping[101] = OCI8::BindType::Float
|
181
|
-
(This is default in ruby-oci8 1.0.0-rc2.)
|
182
|
-
|
183
|
-
But a fetched value may not be exactly same with the value in
|
184
|
-
Oracle. That's because OCI8::BindType::Float's network
|
185
|
-
representation is Oracle NUMBER data type. A BINARY_DOUBLE
|
186
|
-
value in Oracle become NUMBER on the network and is converted
|
187
|
-
to Float on the client side. It makes a bit difference by
|
188
|
-
round-off error.
|
189
|
-
|
190
|
-
In addition, Oracle NUMBER doesn't have NaN, +Infinity and -Infinity.
|
191
|
-
You cannot fetch the values by older versions.
|
192
|
-
|
193
|
-
Note: When you bind a Float value, it is bound by
|
194
|
-
OCI8::BindType::Float by default. You have two ways to bind
|
195
|
-
it by OCI8::BindType::BinaryDouble.
|
196
|
-
|
197
|
-
a. bind explicitly.
|
198
|
-
|
199
|
-
con = OCI8.new('ruby/oci8')
|
200
|
-
csr = con.parse('insert into table_name values (:1)')
|
201
|
-
csr.bind_param(1, 10.5, OCI8::SQLT_IBDOUBLE)
|
202
|
-
csr.exec
|
203
|
-
|
204
|
-
b. change the default behaviour if and only if you are sure that
|
205
|
-
the Oracle client version and Oracle server version are both
|
206
|
-
10g or upper.
|
207
|
-
|
208
|
-
# use OCI8::BindType::BinaryDouble for ruby's Float values.
|
209
|
-
OCI8::BindType::Mapping[Float] = OCI8::BindType::BinaryDouble
|
210
|
-
con = OCI8.new('ruby/oci8')
|
211
|
-
csr = con.exec('insert into table_name values (:1)', 10.5)
|
212
|
-
|
213
|
-
4. OCI8::Cursor#fetch_hash accepts a block as a iterator.
|
214
|
-
|
215
|
-
5. [dbi] support external OS authentication.
|
216
|
-
(contributed by Dan Fitch)
|
217
|
-
|
218
|
-
dbh = DBI.connect('dbi:OCI8', nil, nil)
|
219
|
-
|
220
|
-
6. [dbi] add DatabaseHandle#columns and improve StatementHandle#column_info
|
221
|
-
(suggested by Venkat Pa)
|
222
|
-
|
223
|
-
7. [bug] fix a problem when binding ''(empty string) via dbi.
|
224
|
-
|
225
|
-
1.0.0-rc3:
|
226
|
-
|
227
|
-
1. support external OS authentication.
|
228
|
-
(suggested by Dan Fitch)
|
229
|
-
|
230
|
-
conn = OCI8.new('/')
|
231
|
-
or
|
232
|
-
conn = OCI8.new(nil, nil)
|
233
|
-
|
234
|
-
2. incompatible change on connect string.
|
235
|
-
|
236
|
-
You need to pass only one argument to OCI8.new to parse the
|
237
|
-
first argument as a SQL*Plus-like connect string.
|
238
|
-
|
239
|
-
For example, OCI8.new('scott/tiger', nil) was parsed as the
|
240
|
-
username is 'scott' and the password is 'tiger' in 1.0.0-rc2.
|
241
|
-
But from now on, it is treated as the username is 'scott/tiger'
|
242
|
-
and the password is nil because it has two arguments. You need
|
243
|
-
to use OCI8.new('scott/tiger') instead.
|
244
|
-
|
245
|
-
3. fix NCLOB support on Oracle 9i.
|
246
|
-
(reported by Matthew Noble)
|
247
|
-
|
248
|
-
1.0.0-rc2's NCLOB support worked on Oracle 10g only.
|
249
|
-
|
250
|
-
4. fix a problem to compile with a third-party x86_64 rpm package.
|
251
|
-
(contributed by Jeff Abbott)
|
252
|
-
|
253
|
-
The x86_64 source rpm packages are found on the following URLs.
|
254
|
-
http://freshrpms.net/docs/oracle/
|
255
|
-
http://remi.collet.free.fr/index.php?2007/01/22/279-oracle-instant-client-10203-on-x86_64
|
256
|
-
|
257
|
-
5. '--with-instant-client' option become obsolete and is ignored.
|
258
|
-
|
259
|
-
Use LD_LIBRARY_PATH(Linux), PATH(Windows), etc. to indicate
|
260
|
-
the instant client's location.
|
261
|
-
|
262
|
-
6. fix some other minor problems.
|
263
|
-
|
264
|
-
1.0.0-rc2:
|
265
|
-
|
266
|
-
1. support SQL*Plus-like connect strings.
|
267
|
-
(contributed by Oracle Corporation)
|
268
|
-
|
269
|
-
require 'oci8'
|
270
|
-
conn = OCI8.new('username/password@tns_name')
|
271
|
-
# instead of OCI8.new('username', 'password', 'tns_name')
|
272
|
-
|
273
|
-
2. Add a rpm spec file.
|
274
|
-
(contributed by Brian Candler)
|
275
|
-
|
276
|
-
rpmbuild -tb ruby-oci8-x.y.z.tar.gz
|
277
|
-
|
278
|
-
/usr/src/redhat/RPMS/i386/ruby-oci8-x.y.z-1.i386.rpm
|
279
|
-
|
280
|
-
3. support BINARY_FLOAT and BINADY_DOUBLE columns.
|
281
|
-
(This problem is reported by Duncan McCaffery.)
|
282
|
-
|
283
|
-
4. support NCLOB columns.
|
284
|
-
(This problem is reported by Dmitry Zadvornykh.)
|
285
|
-
|
286
|
-
cursor = conn.exec('select nclob_column from nclob_table')
|
287
|
-
cursor.fetch # => [ instance of OCI8::NCLOB ]
|
288
|
-
|
289
|
-
5. add new CLOB/NCLOB/BLOB insert method.
|
290
|
-
(This is available on Oracle 8.1.5 or later.)
|
291
|
-
|
292
|
-
cursor = conn.parse("INSERT INTO clob_table VALUES (:1)")
|
293
|
-
cursor.bind_param(1, OCI8::CLOB.new(conn, lob_data))
|
294
|
-
cursor.exec
|
295
|
-
|
296
|
-
cursor = conn.parse("INSERT INTO nclob_table VALUES (:1)")
|
297
|
-
cursor.exec(OCI8::NCLOB.new(conn, lob_data))
|
298
|
-
|
299
|
-
conn.exec("INSERT INTO blob_table VALUES (:1)",
|
300
|
-
OCI8::BLOB.new(conn, lob_data))
|
301
|
-
|
302
|
-
This is added to insert CLOB as a SDO_GEOMETRY's parameter
|
303
|
-
to solve a problem reported by Pete Schwamb.
|
304
|
-
|
305
|
-
6. add an error location in C code to OCIException's backtrace.
|
306
|
-
This is for debug information.
|
307
|
-
|
308
|
-
1.0.0-rc1:
|
309
|
-
|
310
|
-
1. support BFILE columns.
|
311
|
-
|
312
|
-
2. check whether Full Client or Instant Client by checking load library
|
313
|
-
path on configuration to compile.
|
314
|
-
|
315
|
-
3. raise an OCIError with "OCI Library Initialization Error" message if
|
316
|
-
no message can not be retrieved when requiring oci8lib.so.
|
317
|
-
|
318
|
-
4. raise "OCI Library Initialization Error" when first connect instead
|
319
|
-
of requiring oci8lib.so. This is a workaround to prevent Rails from
|
320
|
-
being stopped on invalid Oracle environment.
|
321
|
-
|
322
|
-
0.1.16:
|
323
|
-
|
324
|
-
1. Add LONG and LONG RAW support longer than 65535 bytes.
|
325
|
-
|
326
|
-
Use OCI8#long_read_len and OCI8#long_read_len= to set max long length.
|
327
|
-
The default value is 65535.
|
328
|
-
|
329
|
-
2. OraDate and OraNumber can be serialized by Marshal now.
|
330
|
-
|
331
|
-
3. OraDate and OraNumber can be serialized by YAML now.
|
332
|
-
|
333
|
-
4. Fix bug on OraDate#dup, OraDate#clone, OraNumber#dup and OraNumber#clone.
|
334
|
-
(reported by Daniel Berger.)
|
335
|
-
|
336
|
-
These methods had not duplicated their contents, which caused segmentation
|
337
|
-
fault. Now they duplicate their contents also by adding initialize_copy
|
338
|
-
method.
|
339
|
-
|
340
|
-
5. Add a workaround code on cygwin environment variables problem.
|
341
|
-
|
342
|
-
Cygwin manages environment variables by itself. They don't synchroize
|
343
|
-
with Win32's ones. When setting Oracle's environment variables, they
|
344
|
-
are set to cygwin's environment. But Oracle client library read
|
345
|
-
Win32's. Now Oracle-related variables are forcedly set to Win32.
|
346
|
-
|
347
|
-
6. Accept all Fixnum values when binding as a Fixnum on 64-bit ruby.
|
348
|
-
|
349
|
-
A Fixnum is a 31-bit integer on 32-bit ruby, 63-bit integer on 64-bit
|
350
|
-
ruby. But it had been bound to 32-bit integer on ruby-oci8. Now it is
|
351
|
-
bound to integer whose bit width is same with ruby.
|
352
|
-
|
353
|
-
0.1.15:
|
354
|
-
|
355
|
-
1. no new features. :-<
|
356
|
-
|
357
|
-
2. suppress memory usage when binding a placeholder which is already bound.
|
358
|
-
|
359
|
-
require 'oci8'
|
360
|
-
conn = OCI8.new('ruby', 'oci8')
|
361
|
-
cursor = conn.parse('select * from foo where key = :key')
|
362
|
-
0.upto(10000) do |key|
|
363
|
-
# bind values had not freed until cursor.close.
|
364
|
-
# Now they are freed when GC is run.
|
365
|
-
cursor.bind_param('key', key)
|
366
|
-
cursor.exec
|
367
|
-
.... fetch ....
|
368
|
-
end
|
369
|
-
|
370
|
-
3. fix potentially segmentation fault while exiting process.
|
371
|
-
When exiting process, ruby's objects are GCed with unexpectable
|
372
|
-
order. If an OCIEnv instance was GCed in prior to OCIRowid objects,
|
373
|
-
it caused segmentation fault.
|
374
|
-
|
375
|
-
4. add a workaround code when setting $0.
|
376
|
-
The following code made enviroment variables empty strings on
|
377
|
-
Unix when using ruby 1.8.4, ruby-oci8 0.1.14 and Oracle 10.1.0.
|
378
|
-
(Oracle 10.2.0 and ruby 1.8.2 doesn't have this problem.)
|
379
|
-
|
380
|
-
require 'oci8'
|
381
|
-
ENV['HOME'] # --> valid value
|
382
|
-
$0 = 'foo'
|
383
|
-
ENV['HOME'] # --> ''
|
384
|
-
|
385
|
-
5. fix registry search path on compilation.
|
386
|
-
(OracleXE Windows version)
|
387
|
-
|
388
|
-
0.1.14:
|
389
|
-
|
390
|
-
1. add OCI8#prefetch_rows=.
|
391
|
-
|
392
|
-
This specifies the number of rows in a single round trip.
|
393
|
-
See: http://www.easysoft.com/products/data_access/odbc_oracle_driver/performance_tuning_guide.html#multiple_rows
|
394
|
-
In addition, setting zero may become a workaround
|
395
|
-
of some Oracle internal problems.
|
396
|
-
The default value is one.
|
397
|
-
|
398
|
-
2. fix bug when binding a Bignum.
|
399
|
-
3. (low-level API) add attrSet(OCI_ATTR_DESC_PUBLIC, -1).
|
400
|
-
4. (low-level API) add a constant OCI_PTYPE_UNK.
|
401
|
-
5. (internal) use OCIEnv.logon when no priviledge login.
|
402
|
-
6. (internal) delete code to register malloc/realloc/free callbacks to OCI.
|
403
|
-
|
404
|
-
0.1.13:
|
405
|
-
|
406
|
-
1. fix a memory leak.
|
407
|
-
(fixed by Nathaniel Talbott.)
|
408
|
-
|
409
|
-
It is recommended to update to 0.1.13 if a program executes many
|
410
|
-
queries. That's bacause 0.1.12 cause 70-byte memory leak per a
|
411
|
-
query.
|
412
|
-
|
413
|
-
2. ruby's DateTime support is added.
|
414
|
-
(suggested by Daniel Berger.)
|
415
|
-
|
416
|
-
To fetch Oracle's DATE datatype as ruby's DateTime by default, add
|
417
|
-
the following code to your program.
|
418
|
-
|
419
|
-
OCI8::BindType::Mapping[OCI8::SQLT_DAT] = OCI8::BindType::DateTime
|
420
|
-
OCI8::BindType::Mapping[OCI8::SQLT_TIMESTAMP] = OCI8::BindType::DateTime
|
3
|
+
* release a binary gem for Windows, which contains libraries for both
|
4
|
+
ruby 1.8 and ruby 1.9.1.
|
5
|
+
* add OCI8#oracle_server_version.
|
6
|
+
* fix bugs when fetching and binding time objects.
|