forked from kubo/ruby-oci8
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ChangeLog
2321 lines (2027 loc) · 107 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
2011-11-04 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/encoding.yml: fix the mapping from Oracle NLS chacacter set
to ruby encoding to use CP950 and CP951, which are new encodings
in ruby 1.9.3.
2011-11-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c: add a workaround to avoid a gcc internal
compiler error when using ruby 1.9.2-p290 on ubuntu 11.10 (64bit).
(reported by Bob Saveland.)
2011-11-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.c, ext/oci8/oci8.h,
test/test_datetime.rb, test/test_metadata.rb: fix to pass tests
on Oracle 9i.
2011-10-29 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, ext/oci8/oci8.c, lib/oci8/object.rb, lib/oci8/oci8.rb:
reset OCI8#last_error when OCI8#parse or OCI8#exec is called.
fix bugs added by the last commit but one.
2011-10-29 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: use RbConfig::CONFIG instead of obsolete
Config::CONFIG.
2011-10-22 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/attr.c, ext/oci8/bind.c, ext/oci8/connection_pool.c,
ext/oci8/error.c, ext/oci8/lob.c, ext/oci8/metadata.c,
ext/oci8/object.c, ext/oci8/oci8.c, ext/oci8/oci8.h,
ext/oci8/oci8lib.c, ext/oci8/ocidatetime.c, ext/oci8/ocihandle.c,
ext/oci8/ocinumber.c, ext/oci8/stmt.c: add OCI8#last_error and
OCI8#last_error=. When an exception is raised associated with a
connection, the exception is set to OCI8#last_error.
No OCISuccessWithInfo excpetion is raised from now on. It is
set to OCI8#last_error instead.
2011-10-22 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, test/test_break.rb, test/test_error.rb: change the super
class of OCINoData from OCIException to OCIError and fix testcases for
OCIError and its subclasses.
2011-10-22 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c, ext/oci8/oci8.c, ext/oci8/ocinumber.c:
delete code for Oracle 8 and Oracle 8i.
2011-10-21 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, ext/oci8/oci8.h: refactor OCIException and its
subclasses. OCIError#codes and OCIError#messages are deleted.
* test/test_all.rb, test/test_error.rb: add a testcase to check
OCIException's methods.
2011-10-21 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: fix checking code whether 'sys/types.h' is
available for Ubuntu 11.10 where sys/types.h is not right under
/usr/include.
2011-10-21 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: remove code to get linker options for Oracle 8
and Oracle 8i.
2011-10-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: embed a run-time loading path to the extention
library oci8lib_*.so compiled for not only full clients, but also
instant clients on Linux and Solaris.
(suggested by d c and others.)
2011-10-09 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocidatetime.c, lib/oci8/datetime.rb, lib/oci8/object.rb:
add OCI8::BindType::OCITimestamp, OCI8::BindType::LocalDateTime,
OCI8::BindType::UTCDateTime, OCI8::BindType::LocalTime and
OCI8::BindType::UTCTime. The first is used for internal use.
The others are used for timestamp (without time zone) datatype.
2011-10-01 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/attr.c, ext/oci8/ocidatetime.c, ext/oci8/oradate.c: delete
subversion keywords.
* ext/oci8/env.c, ext/oci8/oci8.h, ext/oci8/thread_util.c,
ext/oci8/thread_util.h: use thread-local errhp not only at ruby 1.9
and rubinius, but also ruby 1.8 configured with --enable-pthread.
2011-10-01 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/connection_pool.c, ext/oci8/lob.c,
ext/oci8/metadata.c, ext/oci8/object.c, ext/oci8/oci8.c, ext/oci8/oci8.h,
ext/oci8/oci8lib.c, ext/oci8/ocidatetime.c, ext/oci8/ocihandle.c,
ext/oci8/ocinumber.c, ext/oci8/oradate.c, ext/oci8/stmt.c:
rename oci8_*_class to oci8_*_vtable because they correspond to
virtual method tables (vtable) in C++.
2011-09-30 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.c.tmpl, ext/oci8/oci8lib.c, test/test_break.rb:
clear an executuing thread information in a connection when a SQL
executions is canceled by Thread#kill or Timeout::timeout.
(reported by Aaron Qian)
See: http://rubyforge.org/forum/forum.php?thread_id=50112&forum_id=1078
2011-09-30 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/connection_pool.c: run connection-pool cleanup functions
in a native thread not to block GC.
* ext/oci8/oci8.c: use xfree() instead of free() to release memory
allocated by xmalloc().
2011-08-31 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/env.c, ext/oci8/extconf.rb, ext/oci8/oci8.c, ext/oci8/oci8.h,
ext/oci8/oci8lib.c, ext/oci8/thread_util.c, ext/oci8/thread_util.h:
run connection-cleanup functions in a native thread to correctly
release connections in GC.
2011-08-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c, ext/oci8/oci8.h: refactoring for prior arrangement to
properly release garbage sessions.
2011-08-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/extconf.rb, ext/oci8/lob.c, ext/oci8/object.c,
ext/oci8/oci8.h, ext/oci8/oci8lib.c, ext/oci8/ocidatetime.c,
ext/oci8/ocinumber.c, ext/oci8/oradate.c, ext/oci8/stmt.c,
ext/oci8/xmldb.c: delete unused and unworkable features: dynamic fetch
and xmldb.
2011-08-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, lib/oci8/bindtype.rb, lib/oci8/properties.rb: add
OCI8.properties[:length_semantics].
2011-08-23 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: warn when the Oracle instant client is
64-bit on OS X Lion.
2011-08-19 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/oci8.c, ext/oci8/oci8.h, ext/oci8/ocinumber.c,
lib/oci8/properties.rb: Decimal to float and float to decimal conversions
are done as exactly ruby does by default. The behavior is customizable by
OCI8.properties[:float_conversion_type].
2011-08-19 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: fix a bug not to find the OCI library location listed in
'ldconfig -p' when LD_LIBRARY_PATH is set.
(Reported by Edgars Beigarts.)
2011-07-16 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.h: fix for Solaris compiler.
(Reported by Sanjiv Patel.)
2011-07-16 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: Fix for Oracle 11g solaris-sparc32 instant client.
The machine type of Oracle 10g solaris-sparc32 instant client was
sparc but that of oracle 11g is sparc32plus.
(Reported by Sanjiv Patel.)
2011-06-15 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml, ext/oci8/bind.c, ext/oci8/oci8.c, ext/oci8/oci8lib.c,
lib/oci8/bindtype.rb: drop Oracle 8i support.
* ext/oci8/ocidatetime.c: OCI8::BindType::OCIDate was deleted.
* lib/oci8/datetime.rb, test/test_datetime.rb: OCI8::BindType::DateTimeViaOCIDate,
OCI8::BindType::TimeViaOCIDate, OCI8::BindType::DateTimeViaOCITimestampTZ
and OCI8::BindType::TimeViaOCITimestampTZ were deleted.
2011-06-14 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add changes between 2.0.5 and 2.0.6.
* ext/oci8/apiwrap.yml, ext/oci8/lob.c: fix SEGV when freeing a temporary
LOB during GC on rubinius 1.2.3.
* ext/oci8/oci8lib.c: revert the exception type from RuntimeError to
OCIException when a closed OCI handle's method is called.
It was chaned in 2.0.5 by mistake.
2011-06-12 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add changes between 2.0.4 and 2.0.5.
2011-06-12 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8lib.c: add __declspec(dllexport) to Init_oci8lib(). The mingw32
gcc compiler doesn't export functions without it if more than one function
is declared with it.
* ext/oci8/oraconf.rb: work around for rubinius 1.2.3, which doesn't support
Array#pack('P').
* lib/oci8/oci8.rb: fix a bug introduced by the previous commit.
* ext/oci8/env.c, ext/oci8/extconf.rb, ext/oci8/oci8.c, ext/oci8/oci8.h,
ext/oci8/oci8lib.c: Use HAVE_RB_THREAD_BLOCKING_REGION instead of
HAVE_TYPE_RB_BLOCKING_FUNCTION_T. have_type("rb_blocking_function_t", "ruby.h")
unexpectedly doesn't work on Visual Studio 2010.
2011-06-10 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml, lib/oci8/oci8.rb: fix for Psych YAML library.
* ext/oci8/extconf.rb, ext/oci8/oci8.h, ext/oci8/ocihandle.c: fix to
work with ruby 1.9.3dev.
2011-06-10 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/env.c, ext/oci8/oci8.h: Free OCI error handles on the
native thread termination, not on the ruby thread termination.
(reported by Jordan Curzon and Aaron Qian)
See: http://rubyforge.org/forum/forum.php?thread_id=49751&forum_id=1078
2011-02-21 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c, ext/oci8/metadata.c, ext/oci8/oci8.c,
ext/oci8/oci8.h, ext/oci8/oci8lib.c, ext/oci8/stmt.c:
fix segmentation fault when calling OCI8::Cursor#[] for
closed statement object's (reported by Hugo L. Borges)
2011-02-01 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocidatetime.c, lib/oci8/datetime.rb: rename
the name of the class to binding timestamp with time zone
from OCITimestamp to OCITimestampTZ. OCITimestamp will be
used for timestamp without time zone.
2011-01-30 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: fix SEGV which depends on GC order.
* ext/oci8/oraconf.rb: check Oracle client's cpu type on Solaris as
on Linux and Mac OS X. change error messages on Mac OS X to suggest
to set RC_ARCHS=x86_64 when mkmf.log contains messages such as
'missing required architecture i386 in file.'
2010-12-26 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c, lib/oci8/bindtype.rb, test/test_oranumber.rb:
add OraNumber#has_decimal_part? and OCI8::BindType::BasicNumberType.
2010-12-14 KUBO Takehiro <kubo@jiubao.org>
* dist-files, lib/oci8.rb.in, lib/oci8/.document, lib/oci8/properties.rb:
add OCI8.properties to get and set ruby-oci8 global setting.
* ext/oci8/bind.c, lib/oci8/bindtype.rb: fix NCHAR support and add
OCI8.properties[:bind_string_as_nchar] to control charset form (CHAR or NCHAR)
when binding string values.
See: http://rubyforge.org/forum/forum.php?thread_id=48838&forum_id=1078
2010-12-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/object.c, ext/oci8/bind.c, lib/oci8/object.rb,
test/test_object.rb: fix a problem to assign NULL bind value
to object type bind variables.
(reported by Raimonds Simanovskis)
* ext/oci8/oraconf.rb: fix for 32-bit ruby compiled on
x86_64 linux. (reported by Jason Renschler)
* ext/oci8/oranumber_util.c, test/test_oranumber.rb:
suppress warning: unknown conversion type character 'h' in format
2010-12-04 KUBO Takehiro <kubo@jiubao.org>
* VERSION, ext/oci8/encoding.c, ext/oci8/ocihandle.c: change
the version number to 2.1.
2010-09-18 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/win32.c: undefine boolean to pass compilation on
Cygwin. (reported by Don Hill).
* lib/oci8/encoding-init.rb, lib/oci8/encoding.yml: add a
mapping from ZHT16HKSCS to Big5-HKSCS when the latter
is available in ruby.
2010-09-12 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/env.c, ext/oci8/extconf.rb: suppress warning
'use "ruby/util.h" instead of bare "util.h".'
* test/test_break.rb: make tests insensitive to execution timing.
2010-09-10 KUBO Takehiro <kubo@jiubao.org>
* test/test_array_dml.rb: delete workaround code. It now works
fine on rubinius head.
2010-09-07 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8lib.c: Don't use
rb_set_end_proc() when it isn't available.
* ext/oci8/extconf.rb, lib/oci8.rb.in: add RUBY_ENGINE to
the C extension library name when RUBY_ENGINE is not "ruby."
* ext/oci8/oci8.c: fix for ruby 1.8.
* test/test_clob.rb: change a temporarily used table name for test
from 'test_clob' to 'test_table.'
* test/test_metadata.rb: delete ruby 1.9 feature to work on ruby 1.8.
* test/config.rb: add a support function 'drop_type' for future test
cases.
* test/test_array_dml.rb: skip test_array_insert1 on rubinius.
This will be enabled after the rubinius issue #445 is fixed.
2010-09-05 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.h, ext/oci8/oci8lib.c,
ext/oci8/ocinumber.c: use rb_intern() to retrieve IDs of '+', '-',
'*' and '/' on rubinus.
* ext/oci8/oradate.c: use rb_call_super() instead of
rb_obj_init_copy(), which is not declared in rubinus.
2010-08-28 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/env.c: fix for rubinius.
2010-08-28 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/env.c, ext/oci8/error.c, ext/oci8/extconf.rb, ext/oci8/oci8.c,
ext/oci8/oci8.h, oci8/oci8lib.c, ext/oci8/ocinumber.c: fix for rubinius.
Note that this is not enough to compile ruby-oci8 on it.
2010-08-23 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/object.rb: fix an error when SDO_GEOMETRY is used
and $VERBOSE is set.
* test/test_metadata.rb: (1) fix errors caused by String + Symbol.
They worked on ruby 1.9.2 but not on 1.8.7 and 1.9.2.
(2) replace "assert_equal(class, object.class)" with
"assert_instance_of(class, object)."
* test/test_oranumber.rb: change a testcase for ruby 1.9.2.
Math::atan2(0, 0) behaviour was changed in 1.9.2.
2010-08-15 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c, ext/oci8/object.c, ext/oci8/oci8.h,
lib/oci8/object.rb: support LOB datatypes in Oracle objects.
(reported by Michael Sexton)
* ext/oci8/ocihandle.c: fix SEGV in finalizer when temporary LOBs
are used. This bug was introduced by the previous commit.
2010-08-15 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml, ext/oci8/lob.c: fix memory leak when temporary
lobs are used.
2010-06-15 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/metadata.rb: rename OCI8::Metadata::Column#type_string
to #data_type_string and add an alias from the former to the
latter. fix a return value of OCI8::Metadata::Column#data_type_string
of REF datatype.
* test/test_metadata.rb: rename a test method test_metadata to
test_column_metadata and do refactoring to make test data
reusable for other metadata classes in future.
2010-06-13 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/metadata.c: fix a private method
OCI8::Metadata::Base#__param to return nil when the specified
attribute is NULL.
* lib/oci8/metadata.rb: add rdoc comment of OCI8::Metadata::Type
and fix other typos. change OCI8::Metadata::Schema#all_objects
not to raise "ORA-24372: invalid object for describe" by
invalid objects.
* test/test_metadata.rb: add tests for OCI8::Metadata::Type.
2010-06-11 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/metadata.rb: rename OCI8::Metabase::ProcBase to
OCI8::Metabase::Subprogram, add #is_standalone? and change
#obj_id, #obj_name and #obj_schema to work for packaged
subprograms. Fix rdoc comments.
* test/test_metadata.rb: add tests for OCI8::Metadata::Function,
OCI8::Metadata::Procedure and OCI8::Metadata::Package.
2010-06-10 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/metadata.rb: revice rdoc comments of OCI8::Metadata::Table
and OCI8::Metadata::View and delete some unavailable methods
of OCI8::Metadata::View.
* test/test_metadata.rb: add tests for OCI8::Metadata::Table and
OCI8::Metadata::View.
* README: change the description about the privilege to run tests.
'create view' privilege is needed to test OCI8::Metadata::View.
2010-06-01 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.c, lib/oci8.rb.in: move
the location where OCI8::VERSION is defined from oci8.rb to
oci8lib_*.so. Add code to check the version of oci8.rb and
oci8lib_*.so.
* test/test_clob.rb: create test_clob table while executing
tests.
* README: delete the instruction to create test_clob before
executing tests.
2010-05-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/metadata.c: delete OCI8::Metadata::Base's methods which
get and set OCI handle attributes.
* ext/oci8/ocihandle.c: add OCIHandle#attr_get_oradate.
* lib/oci8/metadata.rb: use OCIHandle#attr_get_* instead of
obsolete OCI8::Metadata::Base#__*.
2010-05-07 KUBO Takehiro <kubo@jiubao.org>
* dist-files, ext/oci8/.document, ext/oci8/apiwrap.yml,
ext/oci8/connection_pool.c, ext/oci8/extconf.rb,ext/oci8/oci8.c,
ext/oci8/oci8.h, ext/oci8/oci8lib.c, lib/oci8.rb.in,
lib/oci8/.document, lib/oci8/connection_pool.rb, lib/oci8/oci8.rb,
lib/oci8/ocihandle.rb: add a new feature OCI8::ConnectionPool.
2010-05-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c: fix a bug that a string is bound to RAW,
its encoding was convertd to OCI.encoding.
* ext/oci8/encoding.c: delete an unused strcuture.
* ext/oci8/oci8.c, ext/oci8/oci8.h, ext/oci8/ocihandle.c,
lib/oci8/oci8.rb: do refactering to make it easy to
implement new authentication features.
* lib/oci8.rb.in, lib/oci8/metadata.rb, lib/oci8/ocihandle.rb:
move constant definitions from metadata.rb to ocihandle.rb.
2010-05-03 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/oci8.h, lib/oci8/bindtype.rb:
change the length semantics from byte to char for string
bind variables when the Oracle client is 9i or upper.
2010-05-02 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/encoding-init.rb: fix for zero-length NLS_LANG.
fix AL32UTF8's nls_ratio.
* ext/oci8/stmt.c: fix SEGV when an exception is raised in
post_bind_hook().
2010-04-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c, ext/oci8/object.c, ext/oci8/oci8.h,
ext/oci8/stmt.c: refactor code to prepare character length
semantics support.
2010-04-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/encoding.c: add new methods OCI8.nls_ratio
and OCI8.nls_ratio=. Comments for rdoc are added and
revised for OCI8#charset_name2id, OCI8#charset_name2id=,
OCI8.encoding and OCI8.encoding=.
* lib/oci8.rb.in, lib/oci8/encoding-init.rb: set
OCI8.nls_ratio on initialization.
2010-04-23 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oranumber_util.c, test/test_oranumber.rb:
add limitted support for OraNumber's positive and negative
infinity. They are converted to '~' and '-~' respectively
as described in <URL:http://www.ixora.com.au/notes/infinity.htm>.
2010-04-23 KUBO Takehiro <kubo@jiubao.org>
* Makefile: fix wrong dependencies in Makefile when running
'make -jNNN (where NNN >= 2)'
(contributed by Alyano Alyanos. See bug #28129 on rubyforge.)
2010-03-07 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c: fix to compile on HP-UX.
Duplicate const qualifiers prevented HP-UX cc from compiling.
(reported by Sebastian YEPES)
2010-02-28 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add changes between 2.0.3 and 2.0.4.
* VERSION: change the version to 2.0.4.
* ext/oci8/stmt.c: fix segmentation fault when OCI8::Cursor#fetch
is called prior to OCI8::Cursor#exec.
* ext/oci8/oci8.c: minor fix in rdoc comment.
2010-02-27 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/datetime.rb: fix a problem that fractional seconds are lost
when Time value is bound to TIMESTAMP.
(reported by Raimonds Simanovskis)
2010-02-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, ext/oci8/extconf.rb, ext/oci8/oci8.h: fix for
old Oracle versions, which lack declarations of OCIMsg, oraub8,
orasb8 and OCI_DURATION_PROCESS.
* ext/oci8/ocihandle.c: fix for mingw compiler.
2010-02-27 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml, ext/oci8/error.c, ext/oci8/oci8.h,
ext/oci8/ocinumber.c: fix for Oracle 8.0 client, which doesn't
have OCIMessageOpen() and OCIMessageGet().
* ext/oci8/oci8.c: add a new method OCI8.error_message to get
a error message which depends on NLS_LANGUAGE.
2010-02-09 KUBO Takehiro <kubo@jiubao.org>
* dist-files: add ext/oci8/oranumber_util.c and
ext/oci8/oranumber_util.h.
(reported by Raimonds Simanovskis)
2010-02-07 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c, ext/oci8/oranumber_util.c,
ext/oci8/oranumber_util.h: change the declaration of
oranumber_to_str() to prevent buffer overflow by
unexpected invalid Oracle number internal data.
2010-02-07 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, ext/oci8/oci8.h: add oci8_raise_by_msgno()
to retrieve a Oracle error message which depends on NLS_LANGUAGE.
* ext/oci8/oranumber_util.c, ext/oci8/oranumber_util.h,
ext/oci8/extconf.rb: add handwritten conversion functions from
OCINumber internal representation to string and vice versa.
* ext/oci8/ocinumber.c: 1. use handwritten conversion functions
instead of OCI functions to convert OraNumber to string
and vice varse. 2. add OraNumber#dump.
* test/test_oranumber.rb: add test cases to check conversion from
OraNumber to string and vice varse.
2010-02-02 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c: fix to support NUMBERS with scale larger
than 38 by using scientific number notation to convert OraNumber
to BigDecimal. OraNumber#to_i is also fixed.
(reported by Raimonds Simanovskis)
2010-01-24 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c: Use OCIErrorGet() to retrieve the error message
when the OCI return code is OCI_NO_DATA.
(reported by Raimonds Simanovskis)
2009-12-06 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/object.c: 1. fix segv when GC starts while initializing
a bind object for object type. (reported by Remi Gagnon)
2. fix memory leak about 30 bytes per one bind object for object
type.
2009-11-03 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/object.c: fix segv when binding a collection of string.
(reported by Raimonds Simanovskis)
2009-10-26 KUBO Takehiro <kubo@jiubao.org>
* NEW: fix typo.
* dist-files, ext/oci8/.document: add ocihandle.c.
* ext/oci8/ocihandle.c: add private methods OCIHandle#attr_get_*,
OCIHandle#attr_set_* and their rdoc comments.
2009-10-23 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.h, ext/oci8/oci8lib.c,
ext/oci8/ocihandle.c: add ocihandle.c and move OCIHandle
definitions from oci8lib.c to the file.
2009-10-21 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add changes between 2.0.2 and 2.0.3.
* VERSION, Makefile: change the version to 2.0.3.
* ext/oci8/oci8.c: fix typo.
* ext/oci8/apiwrap.yml: add OCIIntervalFromText() prototype.
2009-10-18 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocidatetime.c: Add workarounds for Oracle 9.2.0.1.
* lib/oci8/datetime.rb: Change the unit of OCI8::BindType::IntervalDS
from day to second. Add OCI8::BindType::IntervalDS.unit and
OCI8::BindType::IntervalDS.unit=.
* test/test_datetime.rb: Fix tests for the above changes.
2009-10-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: Add a workaround for Oracle 9.2.0.1 when clearing
a client identifier.
* ext/oci8/oci8lib.c: Fix a segv when canceling a non-blocking
execution.
* test_appinfo.rb: Fix temporarily to prevent a segmentation fault
under Oracle 9.2.0.1.
* test/test_oci8.rb: Fix temporarily to prevent a segmentation fault
under Oracle 9.2.0.1. Fix for BigDecimal bundled in ruby 1.8.5.
* test/test_oranumber.rb: Fix for Oracle 9.2. Comparing float values
by <=> is too sensitive to use it in tests.
2009-10-06 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocinumber.c: Add a global function OraNumber(obj) as a
shortcut of OraNumber.new(obj) as Rational and BigDecimal do.
Changes the return type of the four rules of arithmetic;
addition, subtraction, multiplication and division. It was
OraNumber, but now it depends on the operand.
* lib/oci8/bindtype.rb: Add OCI8::BindType::BigDecimal and
OCI8::BindType::Rational. Change the default data type for
number column which fit neither Integer nor Float from
OraNumber to BigDecimal.
* lib/oci8/oci8.rb: Fix for OCI8::BindType::Mapping to accept
a class name instead of the class object to support
OCI8::BindType::BigDecimal and OCI8::BindType::Rational without
requiring 'bigdecimal' and 'rational'.
* spec/oranumber_spec.rb: Add a spec file for OraNumber arithmetic.
* test/test_oci8.rb: Add tests for OCI8::BindType::BigDecimal and
OCI8::BindType::Rational.
2009-10-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: Add constants missing in Oracle client prior to 10g.
* ext/oci8/oraconf.rb:
1. Fix for ruby 1.8.5 with Oracle 8.x which needs some object
files to link with.
(reported by Jayson Cena)
2. Revise the error message under the sudo environemnt.
3. Print not only error message but also the error backtrace when
oraconf.rb fails.
* lib/oci8/object.rb: Fix to accept nil attribute in object type's
constructors. This works only for simple data types such as number,
string. But it doesn't for complex types such as object types.
(requested by Remi Gagnon)
* spec/object_type_spec.rb: Add a test for object type's constructors.
2009-09-22 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/.document, lib/oci8/datetime.rb: 1. Add
OCI8::BindType.default_timezone and OCI8::BindType.default_timezone=.
2. Change the logic to convert to Time and DateTime to adapt DST.
3. Use new features of Time class in ruby 1.9.2 if they are available.
4. Add rdoc comments.
* spec/fetch_datetime8_spec.rb, spec/fetch_datetime_spec.rb,
spec/fetch_time8_spec.rb, spec/fetch_time_spec.rb,
spec/spec_helper.rb: Add tests for OCI8::BindType::DateTime and
OCI8::BindType::Time.
2009-09-13 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c, ext/oci8/oci8.h, test/test_clob.rb: Change
OCI8::LOB#write to accept an object which is not a String and
doesn't respond to 'to_str' as IO#write does.
(requested by Christopher Jones)
2009-09-12 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, lib/oci8.rb.in: Fixed for ruby 1.9.2 preview1.
(pointed by Raimonds Simanovskis)
2009-09-12 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: Fixed to compile for AIX instant clients.
(reported by Kazuya Teramoto)
2009-06-09 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8lib.c: Change the initial polling interval of
non-blocking mode for ruby 1.8 from 100 msec to 10 msec, which
is same with ruby-oci8 1.0.
* ext/oci8/oci8.c: Change the default setting of non-blocking mode
for ruby 1.9 to true. Revise rdoc comments.
2009-06-07 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: revise rdoc comments.
2009-06-05 KUBO Takehiro <kubo@jiubao.org>
* Makefile: check rdoc version when making rdoc documentation.
The rdoc version must be 2.4.
* ext/oci8/.document, ext/oci8/oci8.c, lib/.document,
lib/oci8/.document, lib/oci8/oci8.rb: fix rdoc comments a bit.
2009-05-24 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/object.c, lib/oci8/datetime.rb, lib/oci8/object.rb:
add DATE datatype support in object types.
2009-05-19 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c: delete OCI8::BindType::Fixnum.
* lib/oci8/compat.rb: add OCI8::BindType::Fixnum as an alias
of OCI8::BindType::Integer.
* ext/oci8/extconf.rb: change extconf.rb's argument value of
'--with-oracle-version' to accept dotted version such as
'9.2.0.'
* ext/oci8/oraconf.rb: When extconf.rb fails and it is run
by sudo command, change the error message to notice that
'sudo' may unset environment variables.
2009-05-18 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: revise rdoc comments for OCI8#ping and
OCI8#client_identifier=. Add OCI8#module=, OCI8#action= and
OCI8#client_info.
* test/test_appinfo.rb: add test cases for OCI8#module=,
OCI8#action= and OCI8#client_info.
2009-05-17 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add changes between 2.0.1 and 2.0.2.
* VERSION: change version to 2.0.2.
* dist-files: append newly added files.
* ext/oci8/oci8.c: fix OCI8#ping not to raise an exception
when OCIPing() failed. It should returns true or false.
* ext/oci8/oci8lib.c: Memory allocated by xmalloc() should be
freed by xfree().
2009-05-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/error.c, ext/oci8/extconf.rb, ext/oci8/oci8.h:
fix the native library name in error messages from oci8lib.so
to oci8lib_18.so or oci8lib_191.so.
* ext/oci8/ocinumber.c, test/test_oranumber.rb: fix OraNumber.new
to accept BigDecimal and Rational.
* ext/oci8/bind.c, test/test_oci8.rb: implicitly convert the
specified number to Float when the bind handle is for Float.
* ext/oci8/attr.c: fix for Oracle client which doesn't have
OCIRowidToChar().
* ext/oci8/oci8.c, test/test_appinfo.rb, test/test_all.rb, dist-files:
add new methods OCI8#ping and OCI8#client_identifier=.
add test cases.
* ext/oci8/oci8lib.c: fix a bug for Oracle 8.0.
* lib/oci8/oci8.rb: add a convenient method OCI8#select_one
to fetch one row.
2009-04-18 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/oci8.rb: move OCI8::BindType module to bindtype.rb.
* lib/oci8/bindtype.rb: added. This defines OCI8::BindType.
* lib/oci8.rb.in: require 'oci8/bindtype.rb'
2009-04-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/encoding.c, ext/oci8/lob.c, ext/oci8/metadata.c,
ext/oci8/oci8.c: suppress "warning C4761: integral size mismatch
in argument; conversion supplied" when compiled by Visual C++.
2009-04-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml, ext/oci8/env.c, ext/oci8/extconf.rb,
ext/oci8/oci8.h, ext/oci8/oci8lib.c: OCIEnv is initialized
when it is needed. This makes a basis to enable an event
notification after "require 'oci8'."
* test/test_all.rb: fix a bug added four days ago.
2009-04-14 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.h, ext/oci8/oci8lib.c, ext/oci8/ocinumber.c,
ext/oci8/metadata.c, ext/oci8/object.c: pass an OCIError to
OraNumber functions if it can. (This is the first step to
delay OCIEnv initialization.)
2009-04-14 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: Gets ORACLE_HOME from the Windows regitry
by enumerating subkeys of \\HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE.
2009-04-12 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8/oci8.rb, test/test_encoding.rb: The string bind length should
be got from the string bytesize converted to OCI8.encoding.
2009-04-12 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c: OCI8::BLOB#read should return ASCII-8BIT.
OCI8::BLOB#write should not convert the specified string
to OCI8.encoding.
* test/test_dbi.rb: suppress warning: "shadowing outer local
variable - i"
* test/test_all.rb, test/test_encoding.rb: add string encoding
tests.
2009-04-12 KUBO Takehiro <kubo@jiubao.org>
* lib/dbd/OCI8.rb: fix DBI::DBD::OCI8::BindType::DBIStatementHandle
to pass a newly added sanity check in dbi 0.4.1.
(reported by Dirk Herzhauser)
* test/test_all.rb: fix to use dbi installed as a rubygem.
2009-04-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c: fix an error when executing "select NULL from dual".
http://rubyforge.org/forum/forum.php?thread_id=32468&forum_id=1078
(contributed by Raimonds Simanovskis)
2009-03-24 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.h, ext/oci8/oraconf.rb:
fix a problem when compiling with Oracle 8.0.
(reported by Axel Reinhold)
2009-03-24 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/extconf.rb, ext/oci8/oci8.h: fix a problem when
compiling with Oracle 9.2.
(reported by Axel Reinhold)
* ext/oci8/apiwrap.yml: suppres warnings 'discards qualifiers
from pointer target type' when compiling with Oracle 8i.
2009-03-17 KUBO Takehiro <kubo@jiubao.org>
* NEWS: add a new file.
* VERSION: change version to 2.0.1.
* Makefile: add targets to make a binary gem for Windows.
* dist-files: add NEWS
* ext/oci8/extconf.rb, lib/oci8.rb.in: rename oci8lib.so
to oci8lib_18.so and oci8lib_191.so. The renamed name
depends on the ruby version.
* lib/oci8/datetime.rb: fix the fetched type for date column
when using Oracle 8.x.
* ruby-oci8.gemspec: fix to make a binary gem which contains
both oci8lib_18.so and oci8lib_191.so.
2009-03-17 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml: add prototypes for OCIServerVersion() and
OCIServerRelease().
* ext/oci8/oci8.c: (1) add a private method OCI8#oracle_server_vernum,
which returns Oracle server version number.
(2) fix a class method OCI8.oracle_client_vernum when using Oracle
client 10.1 or lower.
* lib/oci8/datetime.rb: fix year information when fetching a date
whose year is between A.D. 1 and A.D. 139.
* lib/oci8/oci8.rb: (1) add OCI8#oracle_server_version.
* (2) change the default data type for timestamp with time zone
from DateTime to Time.
2009-03-11 KUBO Takehiro <kubo@jiubao.org>
* oraconf.rb: fix big/little endian checking problem on Mac OS X ppc.
(contributed by unknown. See: Bug ID 24284 on rubyforge.)
2009-02-15 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocidatetime.c: fix array DML and DateTime object problem.
OCI8::Cursor#bind_param_array(key, array_of_datetime) didn't
work. (Reported by Leoš Bitto)
* test/test_array_dml.rb: fix to test array DML and DateTime object.
2009-02-10 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/oci8.h, ext/oci8/stmt.c: fix array DML
and DateTime object problem. It didn't work with bind classes
which overwrite 'set' and 'get'. (Reported by Leoš Bitto)
* test/test_array_dml.rb: fix to test array DML and DateTime object.
2009-02-08 KUBO Takehiro <kubo@jiubao.org>
* VERSION: change version from 2.0-svn to 2.0.0 to pass ruby
gem's version string validator.
* ruby-oci8.gemspec: added.
* ext/oci8/extconf.rb, ext/oci8/oci8.h, ext/oci8/oci8lib.c,
ext/oci8/win32.c: 1. add OCI8::Win32Util.dll_path to
retrieve Oracle home location from the OCI.DLL location.
2. add OCI8::Win32Util.enum_homes to get Oracle home and
NLS_LANG pairs in Windows registry.
* lib/oci8/encoding-init.rb: get NLS_LANG from Windows registry
if environment variable NLS_LANG is not set.
* ext/oci8/oraconf.rb: Change the output encoding of sqlplus to
US7ASCII by setting NLS_LANG. If the output encoding is
incompatible with the default external encoding, it raises
'invalid byte sequence' when using ruby 1.9.
* lib/oci8/datetime.rb: fix for ruby 1.9. Ruby 1.9 Time
class's resolution is nanosecond.
* dist-files: add dist-files, ruby-oci8.gemspec and ext/oci8/win32.c.
2009-02-06 KUBO Takehiro <kubo@jiubao.org>
* setup.rb: 1. install lib/**/*.yml flies also.
(It is pointed by Nate Wiger that encoding.yml is not installed.)
2. exclude .svn or .git directories on installation.
* lib/oci8/oci8.rb: A private method define_a_column was renamed
to define_one_column to prevent activerecord oracle adapter
and oracle enhanced adapter from redefining the method.
* dist-files: add newly added file names which must be included
in gem or tar.gz packages.
2009-02-01 KUBO Takehiro <kubo@jiubao.org>
* lib/dbd/OCI8.rb: add code for ruby-dbi 0.4 type conversion.
* test/test_dbi.rb: suppress deprecated warnings while running
test_bind_dbi_data_type.
* test/test_dbi_clob.rb: fix a problem when running this
file directly.
2009-01-31 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: fix for Oracle 11.1.0.7.0 instant
client rpm package. The directory tree is a bit different
with that of 11.1.0.6.0 or earlier.
(reported by Luis Parravicini.)
2009-01-31 KUBO Takehiro <kubo@jiubao.org>
* lib/DBD/OCI8/OCI8.rb: renamed to lib/dbd/OCI8.rb.
* lib/dbd/OCI8.rb: 1. renamed from lib/DBD/OCI8/OCI8.rb
2. fix USED_DBD_VERSION from 0.2 to 0.4.
3. add DBI::DBD::OCI8.driver_name
(changes for ruby-dbi 0.4 contributed by James Cao.)
2009-01-13 KUBO Takehiro <kubo@jiubao.org>
* lib/oci8.rb.in, lib/oci8/encoding-init.rb: (ruby 1.9) set
OCI8.encoding by querying NLS_LANG. If DEFAULT_OCI8_ENCODING
is defined, use it by default.
* lib/oci8/encoding.yml: (ruby 1.9) add a new file containing
mapping table from Oracle characterset name to Ruby encoding
name.
2009-01-11 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/encoding.c: (ruby 1.9) add OCI8.encoding and
OCI8.encoding= to get and set the encoding of the Oracle
library.
* ext/oci8/oci8.h: (ruby 1.9) add macros OCI8StringValue
and OCI8SafeStringValue which convert the string encoding
to Oracle librarie's encoding.
* ext/oci8/oci8.c: OCI8.new raise a SecurityError when specified
connect string is tainted and $SAFE >= 1.
* ext/oci8/stmt.c: OCI8#parse raise a SecurityError when specified
SQL statemenet is tainted and $SAFE >= 1.
* ext/oci8/metadata.c: OCI8#describe_* raise a SecurityError
when the object name to be described is tainted and $SAFE >= 1.
* ext/oci8/lob.c: OCI8::BFILE.new, OCI8::BFILE#dir_alias= and
OCI8::BFILE#filename= raise a SecurityError when specified
dir_alias or filename is tainted and $SAFE >= 1.
* ext/oci8/attr.c, ext/oci8/bind.c, ext/oci8/error.c,
ext/oci8/object.c, ext/oci8/oci8lib.c, ext/oci8/ocinumber.c:
(ruby 1.9) converts encoding from/to OCI.encoding.
2009-01-11 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c: concatenate read data at the end, instead of
appending them for each pieces when reading LOB data.
* test/test_oranumber.rb: fix for ruby 1.9.
2009-01-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.c: delete OCI8.oracle_client_version implemented
in C. add OCI8.oracle_client_vernum whose value is retrieved
by OCIClientVersion() if Oracle 10.2 or upper.
* ext/oci8/oci8.h: add macro rb_define_singleton_method_nodoc,
which prevents rdoc from gathering the specified method.
* lib/.document, lib/oci8/.document: add lib/oci8.rb and
lib/oci8/oracle_version.rb to rdoc targets.
* lib/oci8.rb.in, lib/oci8/oracle_version.rb: add
OCI8::OracleVersion OCI8.oracle_client_version.
* test/config.rb: change version checking code to use
OCI8::OracleVersion.
* test/test_all.rb, test/test_oracle_version.rb: add test cases
of OCI8::OracleVersion.
2009-01-03 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/encoding.c, ext/oci8/error.c, ext/oci8/ocinumber.c,
ext/oci8/oradate.c: use rb_usascii_str_new() or
rb_usascii_str_new_cstr() when its encoding is always
us-ascii.
* ext/oci8/extconf.rb: add type checking for rb_encoding
for ruby 1.9.
* ext/oci8/oci8.h: use rb_str_new(), rb_str_new2() and
rb_tainted_str_new() if rb_usascii_str_new(),
rb_usascii_str_new_cstr() and rb_external_str_new_with_enc()
are not usable.
* ext/oci8/oci8lib.c: use ORAVERNUM macro.
2009-01-03 KUBO Takehiro <kubo@jiubao.org>
* custom-rdoc.rb: fix for rdoc bundled with ruby 1.9.
* ext/oci8/apiwrap.yml, ext/oci8/oci8lib.c: set the value of
OCI8.oracle_client_version by OCIClientVersion() if
the binary is configured with --with-runtime-check and
the Oracle client is 10.2 or upper.
* test/test_oranumber.rb: disable workaround code when
the Oracle client is 10.2.0.4 or upper.
2008-12-30 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/attr.c: rewrite code converting the rowid descriptor
to string representation by using oci8_exec_sql().
* ext/oci8/oci8.c, ext/oci8/oci8.h, ext/oci8/oci8lib.c,
ext/oci8/stmt.c: add check code to ensure that the process id
is not changed.
2008-12-30 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oraconf.rb: add code to check the cpu type of Mac OS X
libclntsh.dylib.
2008-12-21 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml: add OCINlsCharSetNameToId()
* ext/oci8/encoding.c: add OCI8#charset_name2id and
OCI8#charset_id2name.
* ext/oci8/env.c: include <util.h> only when ruby 1.8.
* ext/oci8/oci8.h: don't include <rubyio.h> which is not used
anywhere.
* ext/oci8/ocinumber.c: include <errno.h> to compile
ruby-oci8 for ruby 1.9.
* lib/oci8/metadata.rb: comment duplicated typecode.
* test/test_all.rb: use AutoRunner when it is found.
Ruby 1.9's test unit does't has AutoRunner.
* test/test_oranumber.rb: explicity convert actual_val, which is
passed to before assert_in_delta(), to a Float to prevent
SEGV in OCINumberSub().
2008-12-14 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/stmt.c: fix comment.
* test/test_rowid.rb: add one assertion as ruby-oci8 1.0 branch does.
2008-09-10 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/ocidatetime.c: use session time zone when time zone
is not specified to set bind objects of timestamp with time
zone datatype.
* lib/oci8/datetime.rb: add OCI8::BindType::Util.default_timezone
to get Time or DateTime objects from bind objects of date
datatype.
* test/test_datetime.rb: fix test_datetype_duck_typing and add
test_timezone for the above changes.
2008-09-09 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.rb, ext/oci8/apiwrap.yml, ext/oci8/oci8.h,
ext/oci8/ocidatetime.c, lib/oci8.rb.in, lib/oci8/datetime.rb,
lib/oci8/metadata.rb, lib/oci8/oci8.rb, test/test_break.rb,
test/test_datetime.rb, test/test_dbi.rb, test/test_metadata.rb:
fix Oracle version number mistakes. rename ORAVER_9_1 to
ORAVER_9_0.
2008-08-31 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/bind.c, ext/oci8/stmt.c: disable DYNAMIC_FETCH to fetch
LONG or LONG RAW columns. It doesn't work well.
* lib/oci8/metadata.rb: define char_size for Oracle 8i.
* lib/oci8/oci8.rb: define OCI8::BindType::Long and
OCI8::BindType::LongRaw as subclasses of OCI8::BindType::String
and OCI8::BindType::RAW respectively. fix
OCI8::BindType::String.create and OCI8::BindType::RAW.create
for strings longer than 4000.
* test/test_array_dml.rb: add workaround of "ORA-01036: illegal
variable name/number" by renaming a bind variable name ":N"
to ":1". I guess this is a problem in the Oracle library.
* test/test_break.rb, test/test_dbi.rb, test/test_metadata.rb:
fix test codes for Oracle 8i or lower.
* test/test_oci8.rb: revise a test for LONG columns.
2008-08-28 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.yml: OCINumberSign is unavailable on Oracle 8.
* lib/DBD/OCI8/OCI8.rb: A data dictionary all_constraints doesn't have
index_name column on Oracle 8i or lower. Rewrite
DBI::DBD::OCI8::Database#column by using all_cons_columns.
* lib/oci8/metadata.rb: raise an error when using
* test/config.rb: Oracle 8 desn't have database_compatible_level data
dictionary.
* test/test_metadata.rb: fix test codes for Oracle 8i or lower.
2008-08-26 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/metadata.c: fix bugs when trying to use already freed
OCI8::Metadata::*.
* ext/oci8/ocidatetime.c: fix OCI8::BindType::OCIDate#set().
* ext/oci8/ocinumber.c: undef OraNumber#round_prec and OraNumber
#shift when using Oracle 8.0.
* lib/oci8/datetime.rb, lib/oci8/metadata.rb: fix bugs when using
Oracle 8.0.
* test/config.rb, test/test_dbi.rb, test/test_metadata.rb,
test/test_oci8.rb, test/test_oranumber.rb: do same with the
previous commit.
* test/test_datetime.rb: disable some test cases when Oracle 8.1
or lower.
* test/test_dbi_clob.rb: fix when testing in a deep directory.
2008-08-26 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/apiwrap.c.tmpl, ext/oci8/apiwrap.h.tmpl, ext/oci8/apiwrap.rb
ext/oci8/apiwrap.yml, ext/oci8/bind.c, ext/oci8/extconf.rb,
ext/oci8/oci8.h, ext/oci8/ocidatetime.c, ext/oci8/xmldb.c,
lib/oci8.rb.in, lib/oci8/datetime.rb, lib/oci8/metadata.rb,
lib/oci8/oci8.rb: change oracle version number format.
For example Oracle 9.1.0's version number was represented as 910
in ruby-oci8. Now it is 0x09000000. This format is same with
that of the last argument of OCIServerRelease().
2008-08-10 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c: add workaround code for a losing character problem
when reading CLOB. The problem is happened at the following condition.
1. Oracle client version is 10.2.0.4 or 11.1.0.6.
(It doesn't depend on Oracle server version.)
2. The character set is a variable-length one (e.g. AL32UTF8).
* dist-files: add lib/oci8/datetime.rb and .document files.
2008-08-09 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/lob.c: fix OCI8::LOB#size= when using a lob over 2GB.
fix the return value of OCI8::LOB#write when writing a string
over 2GB.
2008-08-05 KUBO Takehiro <kubo@jiubao.org>
* test/config.rb, test/test_all.rb, test/test_array_dml.rb,
test/test_bind_raw.rb, test/test_bind_time.rb, test/test_break.rb,
test/test_clob.rb, test/test_connstr.rb, test/test_datetime.rb,
test/test_dbi.rb, test/test_dbi_clob.rb, test/test_metadata.rb,
test/test_object.rb, test/test_oci8.rb, test/test_oradate.rb,
test/test_oranumber.rb, test/test_rowid.rb:
fix to run tests in directories outside of 'test' directory.
2008-08-04 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/attr.c: If ORA-01000 (maximum open cursors exceeded) when
converting a rowid descriptor to string representation, run
GC to cleanup unreferenced statement handles and try again.
* ext/oci8/oci8.h, ext/oci8/oci8lib.c: add a utility function
oci8_exec_sql() to execute a SQL statement in C.
* ext/oci8/encoding.c: use oci8_exec_sql() to run anonymous PL/SQL
blocks in oci8_charset_id2name() and oci8_charset_name2id().
* ext/oci8/bind.c, ext/oci8/metadata.c, ext/oci8/ocidatetime.c,
ext/oci8/ocinumber.c: suppress compiler warnings.
* ext/oci8/oci8.c: avoid "[BUG] object allocation during garbage
collection phase" when using ruby 1.9. In GC, just free a
session handle without rollback.
2008-08-02 KUBO Takehiro <kubo@jiubao.org>
* ext/oci8/oci8.h, ext/oci8/ocidatetime.c, lib/oci8.rb.in,
lib/oci8/datetime.rb: change binding code for timestamps
and intervals. C side is a thin wrapper which converts Oracle's