ruby-informix 0.7.3 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
data/COPYRIGHT CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2006-2010, Gerardo Santana Gomez Garrido <gerardo.santana@gmail.com>
1
+ Copyright (c) 2006-2012, Gerardo Santana Gomez Garrido <gerardo.santana@gmail.com>
2
2
  All rights reserved.
3
3
 
4
4
  Redistribution and use in source and binary forms, with or without
data/Changelog CHANGED
@@ -1,3 +1,21 @@
1
+ 0.8.0 2012-04-17
2
+ ------------------
3
+ Bugs fixed:
4
+ * test cases were not loading the just built extension
5
+
6
+ New features:
7
+ * Ruby 1.9.3 compatibility
8
+ * Rake task for running tests
9
+
10
+ Minor changes:
11
+ * Warns to set the Informix environment variables when installing the gem
12
+ * gemspec file added
13
+
14
+ Caveats:
15
+ * It's no longer compatible with Ruby 1.8
16
+ * test cases require test-unit
17
+
18
+
1
19
  0.7.3 2010-02-02
2
20
  ------------------
3
21
  Bugs fixed:
data/README CHANGED
@@ -56,7 +56,7 @@ http://ruby-informix.rubyforge.org/doc
56
56
 
57
57
  === Traversing a table
58
58
 
59
- db.each('select * from stock') do |r|
59
+ db.foreach('select * from stock') do |r|
60
60
  # do something with the record
61
61
  end
62
62
 
@@ -76,7 +76,7 @@ http://ruby-informix.rubyforge.org/doc
76
76
 
77
77
  === Iterating over a table using a hash (shortcut)
78
78
 
79
- db.each_hash('select * from customers') do |cust|
79
+ db.foreach_hash('select * from customers') do |cust|
80
80
  puts "#{cust['firstname']} #{cust['lastname']}"
81
81
  end
82
82
 
@@ -5,7 +5,8 @@ informixdir = ENV["INFORMIXDIR"]
5
5
  MSWindows = /djgpp|(cyg|ms|bcc)win|mingw/
6
6
 
7
7
  if informixdir.nil?
8
- informixdir = RUBY_PLATFORM =~ MSWindows ? "C:/informix" : "/usr/informix"
8
+ warn "Set the Informix environment variables before installing this library"
9
+ exit 1
9
10
  end
10
11
 
11
12
  esql = informixdir + "/bin/esql"
@@ -2,7 +2,7 @@
2
2
  #include <sqliapi.h>
3
3
  #line 1 "informixc.ec"
4
4
  /*
5
- * Copyright (c) 2006-2008, Gerardo Santana Gomez Garrido <gerardo.santana@gmail.com>
5
+ * Copyright (c) 2006-2012, Gerardo Santana Gomez Garrido <gerardo.santana@gmail.com>
6
6
  * All rights reserved.
7
7
  *
8
8
  * Redistribution and use in source and binary forms, with or without
@@ -35,7 +35,7 @@
35
35
  #include <sqlstype.h>
36
36
  #include <sqltypes.h>
37
37
 
38
- static VALUE rb_cDate, rb_cBigDecimal, rb_cRational;
38
+ static VALUE rb_cDate, rb_cBigDecimal;
39
39
 
40
40
  /* Modules */
41
41
  static VALUE rb_mInformix;
@@ -243,7 +243,7 @@ mint i;
243
243
  #line 214 "informixc.ec"
244
244
  static ifx_hostvar_t _SQhtab[] =
245
245
  {
246
- { 0, 11, 103, sizeof(sql_code), 0, 0, 0, 0 },
246
+ { 0, 11, 102, sizeof(sql_code), 0, 0, 0, 0 },
247
247
  { 0, 3, 100, 6, 0, 0, 0, 0 },
248
248
  { 0, 4, 100, 256, 0, 0, 0, 0 },
249
249
  { 0, 5, 100, 256, 0, 0, 0, 0 },
@@ -1241,7 +1241,7 @@ rb_slob_unlock(VALUE self, VALUE offset, VALUE whence, VALUE range)
1241
1241
  typedef enum {
1242
1242
  slob_estbytes, slob_extsz, slob_flags, slob_maxbytes, slob_sbspace
1243
1243
  } slob_option_t;
1244
- static char *str_slob_options[] = {
1244
+ static const char *str_slob_options[] = {
1245
1245
  "estbytes", "extsz", "flags", "maxbytes", "sbspace"};
1246
1246
  /*
1247
1247
  * Base function for getting storage charasteristics
@@ -1485,7 +1485,7 @@ rb_slob_set_flags(VALUE self, VALUE value)
1485
1485
  }
1486
1486
 
1487
1487
  typedef enum { slob_atime, slob_ctime, slob_mtime, slob_refcnt, slob_size } slob_stat_t;
1488
- static char *str_slob_stats[] = {
1488
+ static const char *str_slob_stats[] = {
1489
1489
  "atime", "ctime", "mtime", "refcnt", "size"
1490
1490
  };
1491
1491
 
@@ -2136,8 +2136,7 @@ make_result(cursor_t *c, VALUE record)
2136
2136
  value = rb_funcall(value, s_add, 1, LONG2FIX(sign*seconds));
2137
2137
 
2138
2138
  if (usec != 0) {
2139
- VALUE argv[2] = { INT2FIX(sign*usec), LONG2FIX(1000000L) };
2140
- VALUE frac = rb_class_new_instance(2, argv, rb_cRational);
2139
+ VALUE frac = rb_Rational(INT2FIX(sign*usec), LONG2FIX(1000000L));
2141
2140
  value = rb_funcall(frac, s_add, 1, value);
2142
2141
  }
2143
2142
  }
@@ -2203,8 +2202,8 @@ make_result(cursor_t *c, VALUE record)
2203
2202
  if (BUILTIN_TYPE(record) == T_ARRAY) {
2204
2203
  rb_ary_store(record, i, item);
2205
2204
  }
2206
- else {
2207
- rb_hash_aset(record, RARRAY(c->field_names)->ptr[i], item);
2205
+ else {
2206
+ rb_hash_aset(record, RARRAY_PTR(c->field_names)[i], item);
2208
2207
  }
2209
2208
  }
2210
2209
  return record;
@@ -2219,13 +2218,13 @@ database_free(void *p)
2219
2218
  /*
2220
2219
  * EXEC SQL begin declare section;
2221
2220
  */
2221
+ #line 1924 "informixc.ec"
2222
2222
  #line 1925 "informixc.ec"
2223
- #line 1926 "informixc.ec"
2224
2223
  char *id;
2225
2224
  /*
2226
2225
  * EXEC SQL end declare section;
2227
2226
  */
2228
- #line 1927 "informixc.ec"
2227
+ #line 1926 "informixc.ec"
2229
2228
 
2230
2229
 
2231
2230
  dbt = p;
@@ -2233,11 +2232,11 @@ database_free(void *p)
2233
2232
  /*
2234
2233
  * EXEC SQL disconnect :id;
2235
2234
  */
2236
- #line 1931 "informixc.ec"
2235
+ #line 1930 "informixc.ec"
2237
2236
  {
2238
- #line 1931 "informixc.ec"
2237
+ #line 1930 "informixc.ec"
2239
2238
  sqli_connect_close(0, id, 0, 0);
2240
- #line 1931 "informixc.ec"
2239
+ #line 1930 "informixc.ec"
2241
2240
  }
2242
2241
  xfree(p);
2243
2242
  }
@@ -2264,8 +2263,8 @@ rb_database_initialize(int argc, VALUE *argv, VALUE self)
2264
2263
  /*
2265
2264
  * EXEC SQL begin declare section;
2266
2265
  */
2266
+ #line 1953 "informixc.ec"
2267
2267
  #line 1954 "informixc.ec"
2268
- #line 1955 "informixc.ec"
2269
2268
  char *dbname, *user = NULL, *pass = NULL;
2270
2269
  char *did, *cid, *sid;
2271
2270
  struct version_t
@@ -2276,7 +2275,7 @@ struct version_t
2276
2275
  /*
2277
2276
  * EXEC SQL end declare section;
2278
2277
  */
2279
- #line 1961 "informixc.ec"
2278
+ #line 1960 "informixc.ec"
2280
2279
 
2281
2280
 
2282
2281
  rb_scan_args(argc, argv, "12", &arg[0], &arg[1], &arg[2]);
@@ -2304,24 +2303,24 @@ struct version_t
2304
2303
  * EXEC SQL connect to :dbname as :did user :user
2305
2304
  * using :pass with concurrent transaction;
2306
2305
  */
2307
- #line 1984 "informixc.ec"
2306
+ #line 1983 "informixc.ec"
2308
2307
  {
2309
- #line 1985 "informixc.ec"
2308
+ #line 1984 "informixc.ec"
2310
2309
  ifx_conn_t *_sqiconn;
2311
2310
  _sqiconn = (ifx_conn_t *)ifx_alloc_conn_user(user, pass);
2312
2311
  sqli_connect_open(ESQLINTVERSION, 0, dbname, did, _sqiconn, 1);
2313
2312
  ifx_free_conn_user(&_sqiconn);
2314
- #line 1985 "informixc.ec"
2313
+ #line 1984 "informixc.ec"
2315
2314
  }
2316
2315
  else
2317
2316
  /*
2318
2317
  * EXEC SQL connect to :dbname as :did with concurrent transaction;
2319
2318
  */
2320
- #line 1987 "informixc.ec"
2319
+ #line 1986 "informixc.ec"
2321
2320
  {
2322
- #line 1987 "informixc.ec"
2321
+ #line 1986 "informixc.ec"
2323
2322
  sqli_connect_open(ESQLINTVERSION, 0, dbname, did, (ifx_conn_t *)0, 1);
2324
- #line 1987 "informixc.ec"
2323
+ #line 1986 "informixc.ec"
2325
2324
  }
2326
2325
 
2327
2326
  if (SQLCODE < 0)
@@ -2338,11 +2337,11 @@ struct version_t
2338
2337
  * where c.tabid = ? and c.tabid = d.tabid and c.colno = d.colno
2339
2338
  * order by c.colno';
2340
2339
  */
2341
- #line 1995 "informixc.ec"
2340
+ #line 1994 "informixc.ec"
2342
2341
  {
2343
- #line 2000 "informixc.ec"
2342
+ #line 1999 "informixc.ec"
2344
2343
  sqli_prep(ESQLINTVERSION, sid, "select colname, coltype, collength, extended_id, type, default, c.colno from syscolumns c, outer sysdefaults d where c.tabid = ? and c.tabid = d.tabid and c.colno = d.colno order by c.colno",(ifx_literal_t *)0, (ifx_namelist_t *)0, 2, 0, 0 );
2345
- #line 2000 "informixc.ec"
2344
+ #line 1999 "informixc.ec"
2346
2345
  }
2347
2346
 
2348
2347
  if (SQLCODE < 0)
@@ -2351,11 +2350,11 @@ struct version_t
2351
2350
  /*
2352
2351
  * EXEC SQL declare :cid cursor for :sid;
2353
2352
  */
2354
- #line 2005 "informixc.ec"
2353
+ #line 2004 "informixc.ec"
2355
2354
  {
2356
- #line 2005 "informixc.ec"
2355
+ #line 2004 "informixc.ec"
2357
2356
  sqli_curs_decl_dynm(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 0), cid, sqli_curs_locate(ESQLINTVERSION, sid, 1), 0, 0);
2358
- #line 2005 "informixc.ec"
2357
+ #line 2004 "informixc.ec"
2359
2358
  }
2360
2359
 
2361
2360
  if (SQLCODE < 0)
@@ -2370,17 +2369,17 @@ struct version_t
2370
2369
  * dbinfo('version', 'full')
2371
2370
  * into :c_version from systables where tabid = 1;
2372
2371
  */
2373
- #line 2010 "informixc.ec"
2372
+ #line 2009 "informixc.ec"
2374
2373
  {
2375
- #line 2016 "informixc.ec"
2374
+ #line 2015 "informixc.ec"
2376
2375
  static const char *sqlcmdtxt[] =
2377
- #line 2016 "informixc.ec"
2376
+ #line 2015 "informixc.ec"
2378
2377
  {
2379
- #line 2016 "informixc.ec"
2378
+ #line 2015 "informixc.ec"
2380
2379
  "select dbinfo ( 'version' , 'server-type' ) , dbinfo ( 'version' , 'major' ) , dbinfo ( 'version' , 'minor' ) , dbinfo ( 'version' , 'os' ) , dbinfo ( 'version' , 'level' ) , dbinfo ( 'version' , 'full' ) from systables where tabid = 1",
2381
2380
  0
2382
2381
  };
2383
- #line 2016 "informixc.ec"
2382
+ #line 2015 "informixc.ec"
2384
2383
  static ifx_cursor_t _SQ0 = {0};
2385
2384
  static ifx_sqlvar_t _sqobind[] =
2386
2385
  {
@@ -2390,23 +2389,23 @@ static ifx_cursor_t _SQ0 = {0};
2390
2389
  { 114, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2391
2390
  { 114, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2392
2391
  { 114, 61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2393
- #line 2016 "informixc.ec"
2392
+ #line 2015 "informixc.ec"
2394
2393
  };
2395
- #line 2016 "informixc.ec"
2394
+ #line 2015 "informixc.ec"
2396
2395
  _sqobind[0].sqldata = (c_version).server_type;
2397
- #line 2016 "informixc.ec"
2396
+ #line 2015 "informixc.ec"
2398
2397
  _sqobind[1].sqldata = (c_version).major;
2399
- #line 2016 "informixc.ec"
2398
+ #line 2015 "informixc.ec"
2400
2399
  _sqobind[2].sqldata = (c_version).minor;
2401
- #line 2016 "informixc.ec"
2400
+ #line 2015 "informixc.ec"
2402
2401
  _sqobind[3].sqldata = (c_version).os;
2403
- #line 2016 "informixc.ec"
2402
+ #line 2015 "informixc.ec"
2404
2403
  _sqobind[4].sqldata = (c_version).level;
2405
- #line 2016 "informixc.ec"
2404
+ #line 2015 "informixc.ec"
2406
2405
  _sqobind[5].sqldata = (c_version).full;
2407
- #line 2016 "informixc.ec"
2406
+ #line 2015 "informixc.ec"
2408
2407
  sqli_slct(ESQLINTVERSION, &_SQ0,sqlcmdtxt,0,(ifx_sqlvar_t *)0,6,_sqobind,0,(ifx_literal_t *)0,(ifx_namelist_t *)0,0);
2409
- #line 2016 "informixc.ec"
2408
+ #line 2015 "informixc.ec"
2410
2409
  }
2411
2410
 
2412
2411
 
@@ -2438,13 +2437,13 @@ rb_database_close(VALUE self)
2438
2437
  /*
2439
2438
  * EXEC SQL begin declare section;
2440
2439
  */
2440
+ #line 2043 "informixc.ec"
2441
2441
  #line 2044 "informixc.ec"
2442
- #line 2045 "informixc.ec"
2443
2442
  char *id;
2444
2443
  /*
2445
2444
  * EXEC SQL end declare section;
2446
2445
  */
2447
- #line 2046 "informixc.ec"
2446
+ #line 2045 "informixc.ec"
2448
2447
 
2449
2448
 
2450
2449
  Data_Get_Struct(self, database_t, dbt);
@@ -2452,11 +2451,11 @@ rb_database_close(VALUE self)
2452
2451
  /*
2453
2452
  * EXEC SQL disconnect :id;
2454
2453
  */
2455
- #line 2050 "informixc.ec"
2454
+ #line 2049 "informixc.ec"
2456
2455
  {
2457
- #line 2050 "informixc.ec"
2456
+ #line 2049 "informixc.ec"
2458
2457
  sqli_connect_close(0, id, 0, 0);
2459
- #line 2050 "informixc.ec"
2458
+ #line 2049 "informixc.ec"
2460
2459
  }
2461
2460
 
2462
2461
  return Qnil;
@@ -2488,13 +2487,13 @@ rb_database_immediate(VALUE self, VALUE arg)
2488
2487
  /*
2489
2488
  * EXEC SQL begin declare section;
2490
2489
  */
2490
+ #line 2077 "informixc.ec"
2491
2491
  #line 2078 "informixc.ec"
2492
- #line 2079 "informixc.ec"
2493
2492
  char *query, *did;
2494
2493
  /*
2495
2494
  * EXEC SQL end declare section;
2496
2495
  */
2497
- #line 2080 "informixc.ec"
2496
+ #line 2079 "informixc.ec"
2498
2497
 
2499
2498
 
2500
2499
  Data_Get_Struct(self, database_t, dbt);
@@ -2502,11 +2501,11 @@ rb_database_immediate(VALUE self, VALUE arg)
2502
2501
  /*
2503
2502
  * EXEC SQL set connection :did;
2504
2503
  */
2505
- #line 2084 "informixc.ec"
2504
+ #line 2083 "informixc.ec"
2506
2505
  {
2507
- #line 2084 "informixc.ec"
2506
+ #line 2083 "informixc.ec"
2508
2507
  sqli_connect_set(0, did, 0);
2509
- #line 2084 "informixc.ec"
2508
+ #line 2083 "informixc.ec"
2510
2509
  }
2511
2510
 
2512
2511
  if (SQLCODE < 0)
@@ -2516,11 +2515,11 @@ rb_database_immediate(VALUE self, VALUE arg)
2516
2515
  /*
2517
2516
  * EXEC SQL execute immediate :query;
2518
2517
  */
2519
- #line 2090 "informixc.ec"
2518
+ #line 2089 "informixc.ec"
2520
2519
  {
2521
- #line 2090 "informixc.ec"
2520
+ #line 2089 "informixc.ec"
2522
2521
  sqli_exec_immed(query);
2523
- #line 2090 "informixc.ec"
2522
+ #line 2089 "informixc.ec"
2524
2523
  }
2525
2524
  if (SQLCODE < 0)
2526
2525
  raise_ifx_extended();
@@ -2541,13 +2540,13 @@ rb_database_rollback(VALUE self)
2541
2540
  /*
2542
2541
  * EXEC SQL begin declare section;
2543
2542
  */
2543
+ #line 2106 "informixc.ec"
2544
2544
  #line 2107 "informixc.ec"
2545
- #line 2108 "informixc.ec"
2546
2545
  char *did;
2547
2546
  /*
2548
2547
  * EXEC SQL end declare section;
2549
2548
  */
2550
- #line 2109 "informixc.ec"
2549
+ #line 2108 "informixc.ec"
2551
2550
 
2552
2551
 
2553
2552
  Data_Get_Struct(self, database_t, dbt);
@@ -2555,11 +2554,11 @@ rb_database_rollback(VALUE self)
2555
2554
  /*
2556
2555
  * EXEC SQL set connection :did;
2557
2556
  */
2558
- #line 2113 "informixc.ec"
2557
+ #line 2112 "informixc.ec"
2559
2558
  {
2560
- #line 2113 "informixc.ec"
2559
+ #line 2112 "informixc.ec"
2561
2560
  sqli_connect_set(0, did, 0);
2562
- #line 2113 "informixc.ec"
2561
+ #line 2112 "informixc.ec"
2563
2562
  }
2564
2563
 
2565
2564
  if (SQLCODE < 0)
@@ -2568,11 +2567,11 @@ rb_database_rollback(VALUE self)
2568
2567
  /*
2569
2568
  * EXEC SQL rollback;
2570
2569
  */
2571
- #line 2118 "informixc.ec"
2570
+ #line 2117 "informixc.ec"
2572
2571
  {
2573
- #line 2118 "informixc.ec"
2572
+ #line 2117 "informixc.ec"
2574
2573
  sqli_trans_rollback();
2575
- #line 2118 "informixc.ec"
2574
+ #line 2117 "informixc.ec"
2576
2575
  }
2577
2576
 
2578
2577
  return self;
@@ -2591,13 +2590,13 @@ rb_database_commit(VALUE self)
2591
2590
  /*
2592
2591
  * EXEC SQL begin declare section;
2593
2592
  */
2593
+ #line 2132 "informixc.ec"
2594
2594
  #line 2133 "informixc.ec"
2595
- #line 2134 "informixc.ec"
2596
2595
  char *did;
2597
2596
  /*
2598
2597
  * EXEC SQL end declare section;
2599
2598
  */
2600
- #line 2135 "informixc.ec"
2599
+ #line 2134 "informixc.ec"
2601
2600
 
2602
2601
 
2603
2602
  Data_Get_Struct(self, database_t, dbt);
@@ -2605,11 +2604,11 @@ rb_database_commit(VALUE self)
2605
2604
  /*
2606
2605
  * EXEC SQL set connection :did;
2607
2606
  */
2608
- #line 2139 "informixc.ec"
2607
+ #line 2138 "informixc.ec"
2609
2608
  {
2610
- #line 2139 "informixc.ec"
2609
+ #line 2138 "informixc.ec"
2611
2610
  sqli_connect_set(0, did, 0);
2612
- #line 2139 "informixc.ec"
2611
+ #line 2138 "informixc.ec"
2613
2612
  }
2614
2613
 
2615
2614
  if (SQLCODE < 0)
@@ -2618,11 +2617,11 @@ rb_database_commit(VALUE self)
2618
2617
  /*
2619
2618
  * EXEC SQL commit;
2620
2619
  */
2621
- #line 2144 "informixc.ec"
2620
+ #line 2143 "informixc.ec"
2622
2621
  {
2623
- #line 2144 "informixc.ec"
2622
+ #line 2143 "informixc.ec"
2624
2623
  sqli_trans_commit();
2625
- #line 2144 "informixc.ec"
2624
+ #line 2143 "informixc.ec"
2626
2625
  }
2627
2626
 
2628
2627
  return self;
@@ -2667,13 +2666,13 @@ rb_database_transaction(VALUE self)
2667
2666
  /*
2668
2667
  * EXEC SQL begin declare section;
2669
2668
  */
2669
+ #line 2184 "informixc.ec"
2670
2670
  #line 2185 "informixc.ec"
2671
- #line 2186 "informixc.ec"
2672
2671
  char *did;
2673
2672
  /*
2674
2673
  * EXEC SQL end declare section;
2675
2674
  */
2676
- #line 2187 "informixc.ec"
2675
+ #line 2186 "informixc.ec"
2677
2676
 
2678
2677
 
2679
2678
  Data_Get_Struct(self, database_t, dbt);
@@ -2681,11 +2680,11 @@ rb_database_transaction(VALUE self)
2681
2680
  /*
2682
2681
  * EXEC SQL set connection :did;
2683
2682
  */
2684
- #line 2191 "informixc.ec"
2683
+ #line 2190 "informixc.ec"
2685
2684
  {
2686
- #line 2191 "informixc.ec"
2685
+ #line 2190 "informixc.ec"
2687
2686
  sqli_connect_set(0, did, 0);
2688
- #line 2191 "informixc.ec"
2687
+ #line 2190 "informixc.ec"
2689
2688
  }
2690
2689
 
2691
2690
  if (SQLCODE < 0)
@@ -2694,20 +2693,20 @@ rb_database_transaction(VALUE self)
2694
2693
  /*
2695
2694
  * EXEC SQL commit;
2696
2695
  */
2697
- #line 2196 "informixc.ec"
2696
+ #line 2195 "informixc.ec"
2698
2697
  {
2699
- #line 2196 "informixc.ec"
2698
+ #line 2195 "informixc.ec"
2700
2699
  sqli_trans_commit();
2701
- #line 2196 "informixc.ec"
2700
+ #line 2195 "informixc.ec"
2702
2701
  }
2703
2702
  /*
2704
2703
  * EXEC SQL begin work;
2705
2704
  */
2706
- #line 2197 "informixc.ec"
2705
+ #line 2196 "informixc.ec"
2707
2706
  {
2708
- #line 2197 "informixc.ec"
2707
+ #line 2196 "informixc.ec"
2709
2708
  sqli_trans_begin2((mint)1);
2710
- #line 2197 "informixc.ec"
2709
+ #line 2196 "informixc.ec"
2711
2710
  }
2712
2711
  ret = rb_rescue(rb_yield, self, database_transfail, self);
2713
2712
 
@@ -2717,11 +2716,11 @@ rb_database_transaction(VALUE self)
2717
2716
  /*
2718
2717
  * EXEC SQL commit;
2719
2718
  */
2720
- #line 2203 "informixc.ec"
2719
+ #line 2202 "informixc.ec"
2721
2720
  {
2722
- #line 2203 "informixc.ec"
2721
+ #line 2202 "informixc.ec"
2723
2722
  sqli_trans_commit();
2724
- #line 2203 "informixc.ec"
2723
+ #line 2202 "informixc.ec"
2725
2724
  }
2726
2725
 
2727
2726
  return self;
@@ -2737,8 +2736,8 @@ static VALUE
2737
2736
  rb_database_columns(VALUE self, VALUE tablename)
2738
2737
  {
2739
2738
  VALUE v, column, result;
2740
- char *stype;
2741
- static char *stypes[] = {
2739
+ const char *stype;
2740
+ static const char *stypes[] = {
2742
2741
  "CHAR", "SMALLINT", "INTEGER", "FLOAT", "SMALLFLOAT", "DECIMAL",
2743
2742
  "SERIAL", "DATE", "MONEY", "NULL", "DATETIME", "BYTE",
2744
2743
  "TEXT", "VARCHAR", "INTERVAL", "NCHAR", "NVARCHAR", "INT8",
@@ -2746,7 +2745,7 @@ rb_database_columns(VALUE self, VALUE tablename)
2746
2745
  "VARIABLE-LENGTH OPAQUE TYPE"
2747
2746
  };
2748
2747
 
2749
- static char *qualifiers[] = {
2748
+ static const char *qualifiers[] = {
2750
2749
  "YEAR", "MONTH", "DAY", "HOUR", "MINUTE", "SECOND"
2751
2750
  };
2752
2751
 
@@ -2754,8 +2753,8 @@ rb_database_columns(VALUE self, VALUE tablename)
2754
2753
  /*
2755
2754
  * EXEC SQL begin declare section;
2756
2755
  */
2756
+ #line 2231 "informixc.ec"
2757
2757
  #line 2232 "informixc.ec"
2758
- #line 2233 "informixc.ec"
2759
2758
  char *did, *cid;
2760
2759
  char *tabname;
2761
2760
  int tabid, xid;
@@ -2766,7 +2765,7 @@ short coltype, collength;
2766
2765
  /*
2767
2766
  * EXEC SQL end declare section;
2768
2767
  */
2769
- #line 2240 "informixc.ec"
2768
+ #line 2239 "informixc.ec"
2770
2769
 
2771
2770
 
2772
2771
  Data_Get_Struct(self, database_t, dbt);
@@ -2774,11 +2773,11 @@ short coltype, collength;
2774
2773
  /*
2775
2774
  * EXEC SQL set connection :did;
2776
2775
  */
2777
- #line 2244 "informixc.ec"
2776
+ #line 2243 "informixc.ec"
2778
2777
  {
2779
- #line 2244 "informixc.ec"
2778
+ #line 2243 "informixc.ec"
2780
2779
  sqli_connect_set(0, did, 0);
2781
- #line 2244 "informixc.ec"
2780
+ #line 2243 "informixc.ec"
2782
2781
  }
2783
2782
 
2784
2783
  if (SQLCODE < 0)
@@ -2789,35 +2788,35 @@ short coltype, collength;
2789
2788
  /*
2790
2789
  * EXEC SQL select tabid into :tabid from systables where tabname = :tabname;
2791
2790
  */
2792
- #line 2251 "informixc.ec"
2791
+ #line 2250 "informixc.ec"
2793
2792
  {
2794
- #line 2251 "informixc.ec"
2793
+ #line 2250 "informixc.ec"
2795
2794
  static const char *sqlcmdtxt[] =
2796
- #line 2251 "informixc.ec"
2795
+ #line 2250 "informixc.ec"
2797
2796
  {
2798
- #line 2251 "informixc.ec"
2797
+ #line 2250 "informixc.ec"
2799
2798
  "select tabid from systables where tabname = ?",
2800
2799
  0
2801
2800
  };
2802
- #line 2251 "informixc.ec"
2801
+ #line 2250 "informixc.ec"
2803
2802
  static ifx_cursor_t _SQ0 = {0};
2804
2803
  static ifx_sqlvar_t _sqibind[] =
2805
2804
  {
2806
2805
  { 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2807
- #line 2251 "informixc.ec"
2806
+ #line 2250 "informixc.ec"
2808
2807
  };
2809
2808
  static ifx_sqlvar_t _sqobind[] =
2810
2809
  {
2811
2810
  { 102, sizeof(tabid), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2812
- #line 2251 "informixc.ec"
2811
+ #line 2250 "informixc.ec"
2813
2812
  };
2814
- #line 2251 "informixc.ec"
2813
+ #line 2250 "informixc.ec"
2815
2814
  _sqibind[0].sqldata = tabname;
2816
- #line 2251 "informixc.ec"
2815
+ #line 2250 "informixc.ec"
2817
2816
  _sqobind[0].sqldata = (char *) &tabid;
2818
- #line 2251 "informixc.ec"
2817
+ #line 2250 "informixc.ec"
2819
2818
  sqli_slct(ESQLINTVERSION, &_SQ0,sqlcmdtxt,1,_sqibind,1,_sqobind,0,(ifx_literal_t *)0,(ifx_namelist_t *)0,0);
2820
- #line 2251 "informixc.ec"
2819
+ #line 2250 "informixc.ec"
2821
2820
  }
2822
2821
 
2823
2822
  if (SQLCODE == SQLNOTFOUND)
@@ -2828,19 +2827,19 @@ static ifx_cursor_t _SQ0 = {0};
2828
2827
  /*
2829
2828
  * EXEC SQL open :cid using :tabid;
2830
2829
  */
2831
- #line 2258 "informixc.ec"
2830
+ #line 2257 "informixc.ec"
2832
2831
  {
2833
- #line 2258 "informixc.ec"
2832
+ #line 2257 "informixc.ec"
2834
2833
  static ifx_sqlvar_t _sqibind[] =
2835
2834
  {
2836
2835
  { 102, sizeof(tabid), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2837
- #line 2258 "informixc.ec"
2836
+ #line 2257 "informixc.ec"
2838
2837
  };
2839
2838
  static ifx_sqlda_t _SD0 = { 1, _sqibind, {0}, 1, 0 };
2840
- #line 2258 "informixc.ec"
2839
+ #line 2257 "informixc.ec"
2841
2840
  _sqibind[0].sqldata = (char *) &tabid;
2842
2841
  sqli_curs_open(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), &_SD0, (char *)0, (struct value *)0, 1, 0);
2843
- #line 2258 "informixc.ec"
2842
+ #line 2257 "informixc.ec"
2844
2843
  }
2845
2844
 
2846
2845
  if (SQLCODE < 0)
@@ -2851,9 +2850,9 @@ static ifx_cursor_t _SQ0 = {0};
2851
2850
  * EXEC SQL fetch :cid into :colname, :coltype, :collength, :xid,
2852
2851
  * :deftype, :defvalue;
2853
2852
  */
2854
- #line 2264 "informixc.ec"
2853
+ #line 2263 "informixc.ec"
2855
2854
  {
2856
- #line 2265 "informixc.ec"
2855
+ #line 2264 "informixc.ec"
2857
2856
  static ifx_sqlvar_t _sqobind[] =
2858
2857
  {
2859
2858
  { 114, 129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
@@ -2862,24 +2861,24 @@ static ifx_cursor_t _SQ0 = {0};
2862
2861
  { 102, sizeof(xid), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2863
2862
  { 100, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2864
2863
  { 114, 257, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
2865
- #line 2265 "informixc.ec"
2864
+ #line 2264 "informixc.ec"
2866
2865
  };
2867
2866
  static ifx_sqlda_t _SD0 = { 6, _sqobind, {0}, 6, 0 };
2868
2867
  static _FetchSpec _FS1 = { 0, 1, 0 };
2869
- #line 2265 "informixc.ec"
2868
+ #line 2264 "informixc.ec"
2870
2869
  _sqobind[0].sqldata = colname;
2871
- #line 2265 "informixc.ec"
2870
+ #line 2264 "informixc.ec"
2872
2871
  _sqobind[1].sqldata = (char *) &coltype;
2873
- #line 2265 "informixc.ec"
2872
+ #line 2264 "informixc.ec"
2874
2873
  _sqobind[2].sqldata = (char *) &collength;
2875
- #line 2265 "informixc.ec"
2874
+ #line 2264 "informixc.ec"
2876
2875
  _sqobind[3].sqldata = (char *) &xid;
2877
- #line 2265 "informixc.ec"
2876
+ #line 2264 "informixc.ec"
2878
2877
  _sqobind[4].sqldata = deftype;
2879
- #line 2265 "informixc.ec"
2878
+ #line 2264 "informixc.ec"
2880
2879
  _sqobind[5].sqldata = defvalue;
2881
2880
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, &_SD0, (char *)0, &_FS1);
2882
- #line 2265 "informixc.ec"
2881
+ #line 2264 "informixc.ec"
2883
2882
  }
2884
2883
  if (SQLCODE < 0)
2885
2884
  raise_ifx_extended();
@@ -2977,11 +2976,11 @@ static ifx_cursor_t _SQ0 = {0};
2977
2976
  /*
2978
2977
  * EXEC SQL close :cid;
2979
2978
  */
2980
- #line 2359 "informixc.ec"
2979
+ #line 2358 "informixc.ec"
2981
2980
  {
2982
- #line 2359 "informixc.ec"
2981
+ #line 2358 "informixc.ec"
2983
2982
  sqli_curs_close(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256));
2984
- #line 2359 "informixc.ec"
2983
+ #line 2358 "informixc.ec"
2985
2984
  }
2986
2985
 
2987
2986
  return result;
@@ -3007,13 +3006,13 @@ st_free(cursor_t *c)
3007
3006
  /*
3008
3007
  * EXEC SQL begin declare section;
3009
3008
  */
3009
+ #line 2380 "informixc.ec"
3010
3010
  #line 2381 "informixc.ec"
3011
- #line 2382 "informixc.ec"
3012
3011
  char *sid, *did;
3013
3012
  /*
3014
3013
  * EXEC SQL end declare section;
3015
3014
  */
3016
- #line 2383 "informixc.ec"
3015
+ #line 2382 "informixc.ec"
3017
3016
 
3018
3017
 
3019
3018
  free_input_slots(c);
@@ -3023,11 +3022,11 @@ st_free(cursor_t *c)
3023
3022
  /*
3024
3023
  * EXEC SQL set connection :did;
3025
3024
  */
3026
- #line 2389 "informixc.ec"
3025
+ #line 2388 "informixc.ec"
3027
3026
  {
3028
- #line 2389 "informixc.ec"
3027
+ #line 2388 "informixc.ec"
3029
3028
  sqli_connect_set(0, did, 0);
3030
- #line 2389 "informixc.ec"
3029
+ #line 2388 "informixc.ec"
3031
3030
  }
3032
3031
  if (SQLCODE < 0)
3033
3032
  return;
@@ -3036,11 +3035,11 @@ st_free(cursor_t *c)
3036
3035
  /*
3037
3036
  * EXEC SQL free :sid;
3038
3037
  */
3039
- #line 2394 "informixc.ec"
3038
+ #line 2393 "informixc.ec"
3040
3039
  {
3041
- #line 2394 "informixc.ec"
3040
+ #line 2393 "informixc.ec"
3042
3041
  sqli_curs_free(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 258));
3043
- #line 2394 "informixc.ec"
3042
+ #line 2393 "informixc.ec"
3044
3043
  }
3045
3044
  }
3046
3045
 
@@ -3071,13 +3070,13 @@ rb_statement_initialize(VALUE self, VALUE db, VALUE query)
3071
3070
  /*
3072
3071
  * EXEC SQL begin declare section;
3073
3072
  */
3073
+ #line 2420 "informixc.ec"
3074
3074
  #line 2421 "informixc.ec"
3075
- #line 2422 "informixc.ec"
3076
3075
  char *c_query, *sid, *did;
3077
3076
  /*
3078
3077
  * EXEC SQL end declare section;
3079
3078
  */
3080
- #line 2423 "informixc.ec"
3079
+ #line 2422 "informixc.ec"
3081
3080
 
3082
3081
 
3083
3082
  Data_Get_Struct(db, database_t, dbt);
@@ -3085,11 +3084,11 @@ rb_statement_initialize(VALUE self, VALUE db, VALUE query)
3085
3084
  /*
3086
3085
  * EXEC SQL set connection :did;
3087
3086
  */
3088
- #line 2427 "informixc.ec"
3087
+ #line 2426 "informixc.ec"
3089
3088
  {
3090
- #line 2427 "informixc.ec"
3089
+ #line 2426 "informixc.ec"
3091
3090
  sqli_connect_set(0, did, 0);
3092
- #line 2427 "informixc.ec"
3091
+ #line 2426 "informixc.ec"
3093
3092
  }
3094
3093
  if (SQLCODE < 0)
3095
3094
  raise_ifx_extended();
@@ -3105,11 +3104,11 @@ rb_statement_initialize(VALUE self, VALUE db, VALUE query)
3105
3104
  /*
3106
3105
  * EXEC SQL prepare :sid from :c_query;
3107
3106
  */
3108
- #line 2439 "informixc.ec"
3107
+ #line 2438 "informixc.ec"
3109
3108
  {
3110
- #line 2439 "informixc.ec"
3109
+ #line 2438 "informixc.ec"
3111
3110
  sqli_prep(ESQLINTVERSION, sid, c_query,(ifx_literal_t *)0, (ifx_namelist_t *)0, -1, 0, 0 );
3112
- #line 2439 "informixc.ec"
3111
+ #line 2438 "informixc.ec"
3113
3112
  }
3114
3113
  if (SQLCODE < 0)
3115
3114
  raise_ifx_extended();
@@ -3118,11 +3117,11 @@ rb_statement_initialize(VALUE self, VALUE db, VALUE query)
3118
3117
  /*
3119
3118
  * EXEC SQL describe :sid into output;
3120
3119
  */
3121
- #line 2444 "informixc.ec"
3120
+ #line 2443 "informixc.ec"
3122
3121
  {
3123
- #line 2444 "informixc.ec"
3122
+ #line 2443 "informixc.ec"
3124
3123
  sqli_describe_stmt(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), &output, 0);
3125
- #line 2444 "informixc.ec"
3124
+ #line 2443 "informixc.ec"
3126
3125
  }
3127
3126
  c->daOutput = output;
3128
3127
 
@@ -3169,13 +3168,13 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3169
3168
  /*
3170
3169
  * EXEC SQL begin declare section;
3171
3170
  */
3171
+ #line 2486 "informixc.ec"
3172
3172
  #line 2487 "informixc.ec"
3173
- #line 2488 "informixc.ec"
3174
3173
  char *sid, *did;
3175
3174
  /*
3176
3175
  * EXEC SQL end declare section;
3177
3176
  */
3178
- #line 2489 "informixc.ec"
3177
+ #line 2488 "informixc.ec"
3179
3178
 
3180
3179
 
3181
3180
  Data_Get_Struct(self, cursor_t, c);
@@ -3184,11 +3183,11 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3184
3183
  /*
3185
3184
  * EXEC SQL set connection :did;
3186
3185
  */
3187
- #line 2494 "informixc.ec"
3186
+ #line 2493 "informixc.ec"
3188
3187
  {
3189
- #line 2494 "informixc.ec"
3188
+ #line 2493 "informixc.ec"
3190
3189
  sqli_connect_set(0, did, 0);
3191
- #line 2494 "informixc.ec"
3190
+ #line 2493 "informixc.ec"
3192
3191
  }
3193
3192
  if (SQLCODE < 0)
3194
3193
  raise_ifx_extended();
@@ -3208,11 +3207,11 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3208
3207
  * EXEC SQL execute :sid into descriptor output
3209
3208
  * using descriptor input;
3210
3209
  */
3211
- #line 2509 "informixc.ec"
3210
+ #line 2508 "informixc.ec"
3212
3211
  {
3213
- #line 2510 "informixc.ec"
3212
+ #line 2509 "informixc.ec"
3214
3213
  sqli_exec(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), input, (char *)0, (struct value *)0, output, (char *)0, (struct value *)0, 0);
3215
- #line 2510 "informixc.ec"
3214
+ #line 2509 "informixc.ec"
3216
3215
  }
3217
3216
  clean_input_slots(c);
3218
3217
  }
@@ -3220,11 +3219,11 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3220
3219
  /*
3221
3220
  * EXEC SQL execute :sid into descriptor output;
3222
3221
  */
3223
- #line 2514 "informixc.ec"
3222
+ #line 2513 "informixc.ec"
3224
3223
  {
3225
- #line 2514 "informixc.ec"
3224
+ #line 2513 "informixc.ec"
3226
3225
  sqli_exec(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), (ifx_sqlda_t *)0, (char *)0, (struct value *)0, output, (char *)0, (struct value *)0, 0);
3227
- #line 2514 "informixc.ec"
3226
+ #line 2513 "informixc.ec"
3228
3227
  }
3229
3228
 
3230
3229
  if (SQLCODE < 0)
@@ -3240,11 +3239,11 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3240
3239
  /*
3241
3240
  * EXEC SQL execute :sid using descriptor input;
3242
3241
  */
3243
- #line 2526 "informixc.ec"
3242
+ #line 2525 "informixc.ec"
3244
3243
  {
3245
- #line 2526 "informixc.ec"
3244
+ #line 2525 "informixc.ec"
3246
3245
  sqli_exec(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), input, (char *)0, (struct value *)0, (ifx_sqlda_t *)0, (char *)0, (struct value *)0, 0);
3247
- #line 2526 "informixc.ec"
3246
+ #line 2525 "informixc.ec"
3248
3247
  }
3249
3248
  clean_input_slots(c);
3250
3249
  }
@@ -3252,11 +3251,11 @@ rb_statement_call(int argc, VALUE *argv, VALUE self)
3252
3251
  /*
3253
3252
  * EXEC SQL execute :sid;
3254
3253
  */
3255
- #line 2530 "informixc.ec"
3254
+ #line 2529 "informixc.ec"
3256
3255
  {
3257
- #line 2530 "informixc.ec"
3256
+ #line 2529 "informixc.ec"
3258
3257
  sqli_exec(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), (ifx_sqlda_t *)0, (char *)0, (struct value *)0, (ifx_sqlda_t *)0, (char *)0, (struct value *)0, 0);
3259
- #line 2530 "informixc.ec"
3258
+ #line 2529 "informixc.ec"
3260
3259
  }
3261
3260
  }
3262
3261
  if (SQLCODE < 0)
@@ -3318,13 +3317,13 @@ fetch(VALUE self, VALUE type, VALUE bang)
3318
3317
  /*
3319
3318
  * EXEC SQL begin declare section;
3320
3319
  */
3320
+ #line 2587 "informixc.ec"
3321
3321
  #line 2588 "informixc.ec"
3322
- #line 2589 "informixc.ec"
3323
3322
  char *cid, *did;
3324
3323
  /*
3325
3324
  * EXEC SQL end declare section;
3326
3325
  */
3327
- #line 2590 "informixc.ec"
3326
+ #line 2589 "informixc.ec"
3328
3327
 
3329
3328
  short c_bang;
3330
3329
  cursor_t *c;
@@ -3339,11 +3338,11 @@ fetch(VALUE self, VALUE type, VALUE bang)
3339
3338
  /*
3340
3339
  * EXEC SQL set connection :did;
3341
3340
  */
3342
- #line 2601 "informixc.ec"
3341
+ #line 2600 "informixc.ec"
3343
3342
  {
3344
- #line 2601 "informixc.ec"
3343
+ #line 2600 "informixc.ec"
3345
3344
  sqli_connect_set(0, did, 0);
3346
- #line 2601 "informixc.ec"
3345
+ #line 2600 "informixc.ec"
3347
3346
  }
3348
3347
  if (SQLCODE < 0)
3349
3348
  raise_ifx_extended();
@@ -3354,12 +3353,12 @@ fetch(VALUE self, VALUE type, VALUE bang)
3354
3353
  /*
3355
3354
  * EXEC SQL fetch :cid using descriptor output;
3356
3355
  */
3357
- #line 2608 "informixc.ec"
3356
+ #line 2607 "informixc.ec"
3358
3357
  {
3359
- #line 2608 "informixc.ec"
3358
+ #line 2607 "informixc.ec"
3360
3359
  static _FetchSpec _FS0 = { 0, 1, 0 };
3361
3360
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, output, (char *)0, &_FS0);
3362
- #line 2608 "informixc.ec"
3361
+ #line 2607 "informixc.ec"
3363
3362
  }
3364
3363
  if (SQLCODE < 0)
3365
3364
  raise_ifx_extended();
@@ -3381,13 +3380,13 @@ fetch_many(VALUE self, VALUE n, VALUE type)
3381
3380
  /*
3382
3381
  * EXEC SQL begin declare section;
3383
3382
  */
3383
+ #line 2625 "informixc.ec"
3384
3384
  #line 2626 "informixc.ec"
3385
- #line 2627 "informixc.ec"
3386
3385
  char *cid, *did;
3387
3386
  /*
3388
3387
  * EXEC SQL end declare section;
3389
3388
  */
3390
- #line 2628 "informixc.ec"
3389
+ #line 2627 "informixc.ec"
3391
3390
 
3392
3391
  cursor_t *c;
3393
3392
  struct sqlda *output;
@@ -3403,11 +3402,11 @@ fetch_many(VALUE self, VALUE n, VALUE type)
3403
3402
  /*
3404
3403
  * EXEC SQL set connection :did;
3405
3404
  */
3406
- #line 2640 "informixc.ec"
3405
+ #line 2639 "informixc.ec"
3407
3406
  {
3408
- #line 2640 "informixc.ec"
3407
+ #line 2639 "informixc.ec"
3409
3408
  sqli_connect_set(0, did, 0);
3410
- #line 2640 "informixc.ec"
3409
+ #line 2639 "informixc.ec"
3411
3410
  }
3412
3411
  if (SQLCODE < 0)
3413
3412
  raise_ifx_extended();
@@ -3427,12 +3426,12 @@ fetch_many(VALUE self, VALUE n, VALUE type)
3427
3426
  /*
3428
3427
  * EXEC SQL fetch :cid using descriptor output;
3429
3428
  */
3430
- #line 2656 "informixc.ec"
3429
+ #line 2655 "informixc.ec"
3431
3430
  {
3432
- #line 2656 "informixc.ec"
3431
+ #line 2655 "informixc.ec"
3433
3432
  static _FetchSpec _FS0 = { 0, 1, 0 };
3434
3433
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, output, (char *)0, &_FS0);
3435
- #line 2656 "informixc.ec"
3434
+ #line 2655 "informixc.ec"
3436
3435
  }
3437
3436
  if (SQLCODE < 0)
3438
3437
  raise_ifx_extended();
@@ -3461,13 +3460,13 @@ each(VALUE self, VALUE type, VALUE bang)
3461
3460
  /*
3462
3461
  * EXEC SQL begin declare section;
3463
3462
  */
3463
+ #line 2680 "informixc.ec"
3464
3464
  #line 2681 "informixc.ec"
3465
- #line 2682 "informixc.ec"
3466
3465
  char *cid, *did;
3467
3466
  /*
3468
3467
  * EXEC SQL end declare section;
3469
3468
  */
3470
- #line 2683 "informixc.ec"
3469
+ #line 2682 "informixc.ec"
3471
3470
 
3472
3471
  short c_bang;
3473
3472
  struct sqlda *output;
@@ -3481,11 +3480,11 @@ each(VALUE self, VALUE type, VALUE bang)
3481
3480
  /*
3482
3481
  * EXEC SQL set connection :did;
3483
3482
  */
3484
- #line 2693 "informixc.ec"
3483
+ #line 2692 "informixc.ec"
3485
3484
  {
3486
- #line 2693 "informixc.ec"
3485
+ #line 2692 "informixc.ec"
3487
3486
  sqli_connect_set(0, did, 0);
3488
- #line 2693 "informixc.ec"
3487
+ #line 2692 "informixc.ec"
3489
3488
  }
3490
3489
  if (SQLCODE < 0)
3491
3490
  raise_ifx_extended();
@@ -3497,12 +3496,12 @@ each(VALUE self, VALUE type, VALUE bang)
3497
3496
  /*
3498
3497
  * EXEC SQL fetch :cid using descriptor output;
3499
3498
  */
3500
- #line 2701 "informixc.ec"
3499
+ #line 2700 "informixc.ec"
3501
3500
  {
3502
- #line 2701 "informixc.ec"
3501
+ #line 2700 "informixc.ec"
3503
3502
  static _FetchSpec _FS0 = { 0, 1, 0 };
3504
3503
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, output, (char *)0, &_FS0);
3505
- #line 2701 "informixc.ec"
3504
+ #line 2700 "informixc.ec"
3506
3505
  }
3507
3506
  if (SQLCODE < 0)
3508
3507
  raise_ifx_extended();
@@ -3525,7 +3524,7 @@ each_by(VALUE self, VALUE n, VALUE type)
3525
3524
 
3526
3525
  for(;;) {
3527
3526
  records = fetch_many(self, n, type);
3528
- if (RARRAY(records)->len == 0)
3527
+ if (RARRAY_LEN(records) == 0)
3529
3528
  return self;
3530
3529
  rb_yield(records);
3531
3530
  }
@@ -3564,13 +3563,13 @@ rb_inscur_put(int argc, VALUE *argv, VALUE self)
3564
3563
  /*
3565
3564
  * EXEC SQL begin declare section;
3566
3565
  */
3566
+ #line 2758 "informixc.ec"
3567
3567
  #line 2759 "informixc.ec"
3568
- #line 2760 "informixc.ec"
3569
3568
  char *cid, *did;
3570
3569
  /*
3571
3570
  * EXEC SQL end declare section;
3572
3571
  */
3573
- #line 2761 "informixc.ec"
3572
+ #line 2760 "informixc.ec"
3574
3573
 
3575
3574
 
3576
3575
  Data_Get_Struct(self, cursor_t, c);
@@ -3581,11 +3580,11 @@ rb_inscur_put(int argc, VALUE *argv, VALUE self)
3581
3580
  /*
3582
3581
  * EXEC SQL set connection :did;
3583
3582
  */
3584
- #line 2768 "informixc.ec"
3583
+ #line 2767 "informixc.ec"
3585
3584
  {
3586
- #line 2768 "informixc.ec"
3585
+ #line 2767 "informixc.ec"
3587
3586
  sqli_connect_set(0, did, 0);
3588
- #line 2768 "informixc.ec"
3587
+ #line 2767 "informixc.ec"
3589
3588
  }
3590
3589
  if (SQLCODE < 0)
3591
3590
  raise_ifx_extended();
@@ -3601,11 +3600,11 @@ rb_inscur_put(int argc, VALUE *argv, VALUE self)
3601
3600
  /*
3602
3601
  * EXEC SQL put :cid using descriptor input;
3603
3602
  */
3604
- #line 2780 "informixc.ec"
3603
+ #line 2779 "informixc.ec"
3605
3604
  {
3606
- #line 2780 "informixc.ec"
3605
+ #line 2779 "informixc.ec"
3607
3606
  sqli_curs_put(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), input, (char *)0);
3608
- #line 2780 "informixc.ec"
3607
+ #line 2779 "informixc.ec"
3609
3608
  }
3610
3609
  clean_input_slots(c);
3611
3610
  if (SQLCODE < 0)
@@ -3630,13 +3629,13 @@ rb_inscur_flush(VALUE self)
3630
3629
  /*
3631
3630
  * EXEC SQL begin declare section;
3632
3631
  */
3632
+ #line 2800 "informixc.ec"
3633
3633
  #line 2801 "informixc.ec"
3634
- #line 2802 "informixc.ec"
3635
3634
  char *cid, *did;
3636
3635
  /*
3637
3636
  * EXEC SQL end declare section;
3638
3637
  */
3639
- #line 2803 "informixc.ec"
3638
+ #line 2802 "informixc.ec"
3640
3639
 
3641
3640
 
3642
3641
  Data_Get_Struct(self, cursor_t, c);
@@ -3647,11 +3646,11 @@ rb_inscur_flush(VALUE self)
3647
3646
  /*
3648
3647
  * EXEC SQL set connection :did;
3649
3648
  */
3650
- #line 2810 "informixc.ec"
3649
+ #line 2809 "informixc.ec"
3651
3650
  {
3652
- #line 2810 "informixc.ec"
3651
+ #line 2809 "informixc.ec"
3653
3652
  sqli_connect_set(0, did, 0);
3654
- #line 2810 "informixc.ec"
3653
+ #line 2809 "informixc.ec"
3655
3654
  }
3656
3655
  if (SQLCODE < 0)
3657
3656
  raise_ifx_extended();
@@ -3660,11 +3659,11 @@ rb_inscur_flush(VALUE self)
3660
3659
  /*
3661
3660
  * EXEC SQL flush :cid;
3662
3661
  */
3663
- #line 2815 "informixc.ec"
3662
+ #line 2814 "informixc.ec"
3664
3663
  {
3665
- #line 2815 "informixc.ec"
3664
+ #line 2814 "informixc.ec"
3666
3665
  sqli_curs_flush(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256));
3667
- #line 2815 "informixc.ec"
3666
+ #line 2814 "informixc.ec"
3668
3667
  }
3669
3668
  return self;
3670
3669
  }
@@ -3685,14 +3684,14 @@ rb_scrollcur_entry(VALUE self, VALUE index, VALUE type, VALUE bang)
3685
3684
  /*
3686
3685
  * EXEC SQL begin declare section;
3687
3686
  */
3687
+ #line 2831 "informixc.ec"
3688
3688
  #line 2832 "informixc.ec"
3689
- #line 2833 "informixc.ec"
3690
3689
  char *cid, *did;
3691
3690
  long pos;
3692
3691
  /*
3693
3692
  * EXEC SQL end declare section;
3694
3693
  */
3695
- #line 2835 "informixc.ec"
3694
+ #line 2834 "informixc.ec"
3696
3695
 
3697
3696
 
3698
3697
  Data_Get_Struct(self, cursor_t, c);
@@ -3703,11 +3702,11 @@ long pos;
3703
3702
  /*
3704
3703
  * EXEC SQL set connection :did;
3705
3704
  */
3706
- #line 2842 "informixc.ec"
3705
+ #line 2841 "informixc.ec"
3707
3706
  {
3708
- #line 2842 "informixc.ec"
3707
+ #line 2841 "informixc.ec"
3709
3708
  sqli_connect_set(0, did, 0);
3710
- #line 2842 "informixc.ec"
3709
+ #line 2841 "informixc.ec"
3711
3710
  }
3712
3711
  if (SQLCODE < 0)
3713
3712
  return Qnil;
@@ -3719,60 +3718,60 @@ long pos;
3719
3718
  /*
3720
3719
  * EXEC SQL fetch current :cid using descriptor output;
3721
3720
  */
3722
- #line 2850 "informixc.ec"
3721
+ #line 2849 "informixc.ec"
3723
3722
  {
3724
- #line 2850 "informixc.ec"
3723
+ #line 2849 "informixc.ec"
3725
3724
  static _FetchSpec _FS0 = { 0, 5, 0 };
3726
3725
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, output, (char *)0, &_FS0);
3727
- #line 2850 "informixc.ec"
3726
+ #line 2849 "informixc.ec"
3728
3727
  }
3729
3728
  else if ((pos = NUM2LONG(index) + 1) > 0)
3730
3729
  /*
3731
3730
  * EXEC SQL fetch absolute :pos :cid using descriptor output;
3732
3731
  */
3733
- #line 2852 "informixc.ec"
3732
+ #line 2851 "informixc.ec"
3734
3733
  {
3735
- #line 2852 "informixc.ec"
3734
+ #line 2851 "informixc.ec"
3736
3735
  static ifx_sqlvar_t _sqibind[] =
3737
3736
  {
3738
3737
  { 103, sizeof(pos), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
3739
- #line 2852 "informixc.ec"
3738
+ #line 2851 "informixc.ec"
3740
3739
  };
3741
3740
  static ifx_sqlda_t _SD0 = { 1, _sqibind, {0}, 1, 0 };
3742
3741
  static _FetchSpec _FS1 = { 0, 6, 0 };
3743
- #line 2852 "informixc.ec"
3742
+ #line 2851 "informixc.ec"
3744
3743
  _sqibind[0].sqldata = (char *) &pos;
3745
3744
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), &_SD0, output, (char *)0, &_FS1);
3746
- #line 2852 "informixc.ec"
3745
+ #line 2851 "informixc.ec"
3747
3746
  }
3748
3747
  else {
3749
3748
  /*
3750
3749
  * EXEC SQL fetch last :cid;
3751
3750
  */
3752
- #line 2854 "informixc.ec"
3751
+ #line 2853 "informixc.ec"
3753
3752
  {
3754
- #line 2854 "informixc.ec"
3753
+ #line 2853 "informixc.ec"
3755
3754
  static _FetchSpec _FS0 = { 0, 4, 0 };
3756
3755
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, (ifx_sqlda_t *)0, (char *)0, &_FS0);
3757
- #line 2854 "informixc.ec"
3756
+ #line 2853 "informixc.ec"
3758
3757
  }
3759
3758
  /*
3760
3759
  * EXEC SQL fetch relative :pos :cid using descriptor output;
3761
3760
  */
3762
- #line 2855 "informixc.ec"
3761
+ #line 2854 "informixc.ec"
3763
3762
  {
3764
- #line 2855 "informixc.ec"
3763
+ #line 2854 "informixc.ec"
3765
3764
  static ifx_sqlvar_t _sqibind[] =
3766
3765
  {
3767
3766
  { 103, sizeof(pos), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
3768
- #line 2855 "informixc.ec"
3767
+ #line 2854 "informixc.ec"
3769
3768
  };
3770
3769
  static ifx_sqlda_t _SD0 = { 1, _sqibind, {0}, 1, 0 };
3771
3770
  static _FetchSpec _FS1 = { 0, 7, 0 };
3772
- #line 2855 "informixc.ec"
3771
+ #line 2854 "informixc.ec"
3773
3772
  _sqibind[0].sqldata = (char *) &pos;
3774
3773
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), &_SD0, output, (char *)0, &_FS1);
3775
- #line 2855 "informixc.ec"
3774
+ #line 2854 "informixc.ec"
3776
3775
  }
3777
3776
  }
3778
3777
 
@@ -3800,14 +3799,14 @@ rb_scrollcur_rel(VALUE self, VALUE offset, VALUE type, VALUE bang)
3800
3799
  /*
3801
3800
  * EXEC SQL begin declare section;
3802
3801
  */
3802
+ #line 2878 "informixc.ec"
3803
3803
  #line 2879 "informixc.ec"
3804
- #line 2880 "informixc.ec"
3805
3804
  char *cid, *did;
3806
3805
  long pos;
3807
3806
  /*
3808
3807
  * EXEC SQL end declare section;
3809
3808
  */
3810
- #line 2882 "informixc.ec"
3809
+ #line 2881 "informixc.ec"
3811
3810
 
3812
3811
 
3813
3812
  Data_Get_Struct(self, cursor_t, c);
@@ -3818,11 +3817,11 @@ long pos;
3818
3817
  /*
3819
3818
  * EXEC SQL set connection :did;
3820
3819
  */
3821
- #line 2889 "informixc.ec"
3820
+ #line 2888 "informixc.ec"
3822
3821
  {
3823
- #line 2889 "informixc.ec"
3822
+ #line 2888 "informixc.ec"
3824
3823
  sqli_connect_set(0, did, 0);
3825
- #line 2889 "informixc.ec"
3824
+ #line 2888 "informixc.ec"
3826
3825
  }
3827
3826
  if (SQLCODE < 0)
3828
3827
  return Qnil;
@@ -3834,20 +3833,20 @@ long pos;
3834
3833
  /*
3835
3834
  * EXEC SQL fetch relative :pos :cid using descriptor output;
3836
3835
  */
3837
- #line 2897 "informixc.ec"
3836
+ #line 2896 "informixc.ec"
3838
3837
  {
3839
- #line 2897 "informixc.ec"
3838
+ #line 2896 "informixc.ec"
3840
3839
  static ifx_sqlvar_t _sqibind[] =
3841
3840
  {
3842
3841
  { 103, sizeof(pos), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
3843
- #line 2897 "informixc.ec"
3842
+ #line 2896 "informixc.ec"
3844
3843
  };
3845
3844
  static ifx_sqlda_t _SD0 = { 1, _sqibind, {0}, 1, 0 };
3846
3845
  static _FetchSpec _FS1 = { 0, 7, 0 };
3847
- #line 2897 "informixc.ec"
3846
+ #line 2896 "informixc.ec"
3848
3847
  _sqibind[0].sqldata = (char *) &pos;
3849
3848
  sqli_curs_fetch(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), &_SD0, output, (char *)0, &_FS1);
3850
- #line 2897 "informixc.ec"
3849
+ #line 2896 "informixc.ec"
3851
3850
  }
3852
3851
 
3853
3852
  if (SQLCODE == SQLNOTFOUND)
@@ -3869,13 +3868,13 @@ cursorbase_close_or_free(cursor_t *c, short op)
3869
3868
  /*
3870
3869
  * EXEC SQL begin declare section;
3871
3870
  */
3871
+ #line 2914 "informixc.ec"
3872
3872
  #line 2915 "informixc.ec"
3873
- #line 2916 "informixc.ec"
3874
3873
  char *cid, *did;
3875
3874
  /*
3876
3875
  * EXEC SQL end declare section;
3877
3876
  */
3878
- #line 2917 "informixc.ec"
3877
+ #line 2916 "informixc.ec"
3879
3878
 
3880
3879
 
3881
3880
  if (op == 1 && !c->is_open)
@@ -3891,11 +3890,11 @@ cursorbase_close_or_free(cursor_t *c, short op)
3891
3890
  /*
3892
3891
  * EXEC SQL set connection :did;
3893
3892
  */
3894
- #line 2929 "informixc.ec"
3893
+ #line 2928 "informixc.ec"
3895
3894
  {
3896
- #line 2929 "informixc.ec"
3895
+ #line 2928 "informixc.ec"
3897
3896
  sqli_connect_set(0, did, 0);
3898
- #line 2929 "informixc.ec"
3897
+ #line 2928 "informixc.ec"
3899
3898
  }
3900
3899
  if (SQLCODE < 0)
3901
3900
  return;
@@ -3903,22 +3902,22 @@ cursorbase_close_or_free(cursor_t *c, short op)
3903
3902
  /*
3904
3903
  * EXEC SQL close :cid;
3905
3904
  */
3906
- #line 2933 "informixc.ec"
3905
+ #line 2932 "informixc.ec"
3907
3906
  {
3908
- #line 2933 "informixc.ec"
3907
+ #line 2932 "informixc.ec"
3909
3908
  sqli_curs_close(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256));
3910
- #line 2933 "informixc.ec"
3909
+ #line 2932 "informixc.ec"
3911
3910
  }
3912
3911
  if (op == 1)
3913
3912
  break;
3914
3913
  /*
3915
3914
  * EXEC SQL free :cid;
3916
3915
  */
3917
- #line 2936 "informixc.ec"
3916
+ #line 2935 "informixc.ec"
3918
3917
  {
3919
- #line 2936 "informixc.ec"
3918
+ #line 2935 "informixc.ec"
3920
3919
  sqli_curs_free(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 258));
3921
- #line 2936 "informixc.ec"
3920
+ #line 2935 "informixc.ec"
3922
3921
  }
3923
3922
  st_free(c);
3924
3923
  break;
@@ -3986,13 +3985,13 @@ rb_cursorbase_open(int argc, VALUE *argv, VALUE self)
3986
3985
  /*
3987
3986
  * EXEC SQL begin declare section;
3988
3987
  */
3988
+ #line 2999 "informixc.ec"
3989
3989
  #line 3000 "informixc.ec"
3990
- #line 3001 "informixc.ec"
3991
3990
  char *cid, *did;
3992
3991
  /*
3993
3992
  * EXEC SQL end declare section;
3994
3993
  */
3995
- #line 3002 "informixc.ec"
3994
+ #line 3001 "informixc.ec"
3996
3995
 
3997
3996
 
3998
3997
  Data_Get_Struct(self, cursor_t, c);
@@ -4004,11 +4003,11 @@ rb_cursorbase_open(int argc, VALUE *argv, VALUE self)
4004
4003
  /*
4005
4004
  * EXEC SQL set connection :did;
4006
4005
  */
4007
- #line 3010 "informixc.ec"
4006
+ #line 3009 "informixc.ec"
4008
4007
  {
4009
- #line 3010 "informixc.ec"
4008
+ #line 3009 "informixc.ec"
4010
4009
  sqli_connect_set(0, did, 0);
4011
- #line 3010 "informixc.ec"
4010
+ #line 3009 "informixc.ec"
4012
4011
  }
4013
4012
  if (SQLCODE < 0)
4014
4013
  raise_ifx_extended();
@@ -4027,11 +4026,11 @@ rb_cursorbase_open(int argc, VALUE *argv, VALUE self)
4027
4026
  * EXEC SQL open :cid using descriptor input
4028
4027
  * with reoptimization;
4029
4028
  */
4030
- #line 3024 "informixc.ec"
4029
+ #line 3023 "informixc.ec"
4031
4030
  {
4032
- #line 3025 "informixc.ec"
4031
+ #line 3024 "informixc.ec"
4033
4032
  sqli_curs_open(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), input, (char *)0, (struct value *)0, 1, 1);
4034
- #line 3025 "informixc.ec"
4033
+ #line 3024 "informixc.ec"
4035
4034
  }
4036
4035
  clean_input_slots(c);
4037
4036
  }
@@ -4039,22 +4038,22 @@ rb_cursorbase_open(int argc, VALUE *argv, VALUE self)
4039
4038
  /*
4040
4039
  * EXEC SQL open :cid with reoptimization;
4041
4040
  */
4042
- #line 3029 "informixc.ec"
4041
+ #line 3028 "informixc.ec"
4043
4042
  {
4044
- #line 3029 "informixc.ec"
4043
+ #line 3028 "informixc.ec"
4045
4044
  sqli_curs_open(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, (char *)0, (struct value *)0, 0, 1);
4046
- #line 3029 "informixc.ec"
4045
+ #line 3028 "informixc.ec"
4047
4046
  }
4048
4047
  }
4049
4048
  else
4050
4049
  /*
4051
4050
  * EXEC SQL open :cid;
4052
4051
  */
4053
- #line 3032 "informixc.ec"
4052
+ #line 3031 "informixc.ec"
4054
4053
  {
4055
- #line 3032 "informixc.ec"
4054
+ #line 3031 "informixc.ec"
4056
4055
  sqli_curs_open(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 256), (ifx_sqlda_t *)0, (char *)0, (struct value *)0, 0, 0);
4057
- #line 3032 "informixc.ec"
4056
+ #line 3031 "informixc.ec"
4058
4057
  }
4059
4058
 
4060
4059
  if (SQLCODE < 0)
@@ -4116,14 +4115,14 @@ rb_cursor_s_new0(int argc, VALUE *argv, VALUE self)
4116
4115
  /*
4117
4116
  * EXEC SQL begin declare section;
4118
4117
  */
4118
+ #line 3089 "informixc.ec"
4119
4119
  #line 3090 "informixc.ec"
4120
- #line 3091 "informixc.ec"
4121
4120
  char *c_query;
4122
4121
  char *cid, *sid, *did;
4123
4122
  /*
4124
4123
  * EXEC SQL end declare section;
4125
4124
  */
4126
- #line 3093 "informixc.ec"
4125
+ #line 3092 "informixc.ec"
4127
4126
 
4128
4127
 
4129
4128
  memset(&c, 0, sizeof(c));
@@ -4133,11 +4132,11 @@ rb_cursor_s_new0(int argc, VALUE *argv, VALUE self)
4133
4132
  /*
4134
4133
  * EXEC SQL set connection :did;
4135
4134
  */
4136
- #line 3099 "informixc.ec"
4135
+ #line 3098 "informixc.ec"
4137
4136
  {
4138
- #line 3099 "informixc.ec"
4137
+ #line 3098 "informixc.ec"
4139
4138
  sqli_connect_set(0, did, 0);
4140
- #line 3099 "informixc.ec"
4139
+ #line 3098 "informixc.ec"
4141
4140
  }
4142
4141
 
4143
4142
  if (SQLCODE < 0)
@@ -4161,11 +4160,11 @@ rb_cursor_s_new0(int argc, VALUE *argv, VALUE self)
4161
4160
  /*
4162
4161
  * EXEC SQL prepare :sid from :c_query;
4163
4162
  */
4164
- #line 3119 "informixc.ec"
4163
+ #line 3118 "informixc.ec"
4165
4164
  {
4166
- #line 3119 "informixc.ec"
4165
+ #line 3118 "informixc.ec"
4167
4166
  sqli_prep(ESQLINTVERSION, sid, c_query,(ifx_literal_t *)0, (ifx_namelist_t *)0, -1, 0, 0 );
4168
- #line 3119 "informixc.ec"
4167
+ #line 3118 "informixc.ec"
4169
4168
  }
4170
4169
  if (SQLCODE < 0)
4171
4170
  raise_ifx_extended();
@@ -4174,41 +4173,41 @@ rb_cursor_s_new0(int argc, VALUE *argv, VALUE self)
4174
4173
  /*
4175
4174
  * EXEC SQL declare :cid scroll cursor with hold for :sid;
4176
4175
  */
4177
- #line 3124 "informixc.ec"
4176
+ #line 3123 "informixc.ec"
4178
4177
  {
4179
- #line 3124 "informixc.ec"
4178
+ #line 3123 "informixc.ec"
4180
4179
  sqli_curs_decl_dynm(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 0), cid, sqli_curs_locate(ESQLINTVERSION, sid, 1), 4128, 0);
4181
- #line 3124 "informixc.ec"
4180
+ #line 3123 "informixc.ec"
4182
4181
  }
4183
4182
  else if (RTEST(hold))
4184
4183
  /*
4185
4184
  * EXEC SQL declare :cid cursor with hold for :sid;
4186
4185
  */
4187
- #line 3126 "informixc.ec"
4186
+ #line 3125 "informixc.ec"
4188
4187
  {
4189
- #line 3126 "informixc.ec"
4188
+ #line 3125 "informixc.ec"
4190
4189
  sqli_curs_decl_dynm(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 0), cid, sqli_curs_locate(ESQLINTVERSION, sid, 1), 4096, 0);
4191
- #line 3126 "informixc.ec"
4190
+ #line 3125 "informixc.ec"
4192
4191
  }
4193
4192
  else if (RTEST(scroll))
4194
4193
  /*
4195
4194
  * EXEC SQL declare :cid scroll cursor for :sid;
4196
4195
  */
4197
- #line 3128 "informixc.ec"
4196
+ #line 3127 "informixc.ec"
4198
4197
  {
4199
- #line 3128 "informixc.ec"
4198
+ #line 3127 "informixc.ec"
4200
4199
  sqli_curs_decl_dynm(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 0), cid, sqli_curs_locate(ESQLINTVERSION, sid, 1), 32, 0);
4201
- #line 3128 "informixc.ec"
4200
+ #line 3127 "informixc.ec"
4202
4201
  }
4203
4202
  else
4204
4203
  /*
4205
4204
  * EXEC SQL declare :cid cursor for :sid;
4206
4205
  */
4207
- #line 3130 "informixc.ec"
4206
+ #line 3129 "informixc.ec"
4208
4207
  {
4209
- #line 3130 "informixc.ec"
4208
+ #line 3129 "informixc.ec"
4210
4209
  sqli_curs_decl_dynm(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, cid, 0), cid, sqli_curs_locate(ESQLINTVERSION, sid, 1), 0, 0);
4211
- #line 3130 "informixc.ec"
4210
+ #line 3129 "informixc.ec"
4212
4211
  }
4213
4212
 
4214
4213
  if (SQLCODE < 0)
@@ -4218,11 +4217,11 @@ rb_cursor_s_new0(int argc, VALUE *argv, VALUE self)
4218
4217
  /*
4219
4218
  * EXEC SQL describe :sid into output;
4220
4219
  */
4221
- #line 3136 "informixc.ec"
4220
+ #line 3135 "informixc.ec"
4222
4221
  {
4223
- #line 3136 "informixc.ec"
4222
+ #line 3135 "informixc.ec"
4224
4223
  sqli_describe_stmt(ESQLINTVERSION, sqli_curs_locate(ESQLINTVERSION, sid, 257), &output, 0);
4225
- #line 3136 "informixc.ec"
4224
+ #line 3135 "informixc.ec"
4226
4225
  }
4227
4226
  c.daOutput = output;
4228
4227
 
@@ -4465,8 +4464,6 @@ void Init_informixc(void)
4465
4464
  rb_require("bigdecimal");
4466
4465
  rb_cBigDecimal = rb_const_get(rb_cObject, rb_intern("BigDecimal"));
4467
4466
 
4468
- rb_cRational = rb_const_get(rb_cObject, rb_intern("Rational"));
4469
-
4470
4467
  rb_require("informix/exceptions");
4471
4468
  rb_eError = rb_const_get(rb_mInformix, rb_intern("Error"));
4472
4469
  rb_eWarning = rb_const_get(rb_mInformix, rb_intern("Warning"));
@@ -4513,4 +4510,4 @@ void Init_informixc(void)
4513
4510
  sym_params = ID2SYM(rb_intern("params"));
4514
4511
  }
4515
4512
 
4516
- #line 3424 "informixc.ec"
4513
+ #line 3421 "informixc.ec"