# Ruby

**URL:** https://www.ruby-forum.com/c/ruby/7.md?page=1046

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 1047

---

## [About RAILS](https://www.ruby-forum.com/t/about-rails/145965)

<div class="topic-metadata">

**Author:** [@Alexandre\_Brillant](https://www.ruby-forum.com/u/Alexandre_Brillant)\
**Replies:** 4\
**Last updated:** [August 15, 2008, 4:55pm UTC](https://www.ruby-forum.com/t/about-rails/145965 "2008-08-15T16:55:35Z")

</div>

Hi, I don’t understand one point with Ruby on Rails : I have the following migration file : class Personne \< ActiveRecord::Migration def self.up Commentaire à enlever si vous avez déjà une table personnes drop\_table…

---

## [setIncludeSynonyms()](https://www.ruby-forum.com/t/setincludesynonyms/145959)

<div class="topic-metadata">

**Author:** [@ddirk](https://www.ruby-forum.com/u/ddirk)\
**Replies:** 0\
**Last updated:** [August 15, 2008, 3:05pm UTC](https://www.ruby-forum.com/t/setincludesynonyms/145959 "2008-08-15T15:05:22Z")

</div>

Hi, whats the proper way to call setIncludeSynonyms() on the underlying JDBC connection (using active\_record and jdbc\_adapter)? http://www.princeton.edu/storacle/jdbc8\_doc/oracle.jdbc.driver.OracleConnection.html#setI…

---

## [Re: Code Review: warning2](https://www.ruby-forum.com/t/re-code-review-warning2/145939)

<div class="topic-metadata">

**Author:** [@raker\_t](https://www.ruby-forum.com/u/raker_t)\
**Replies:** 2\
**Last updated:** [August 15, 2008, 3:00pm UTC](https://www.ruby-forum.com/t/re-code-review-warning2/145939 "2008-08-15T15:00:00Z")

</div>

I’ll reply to both patches with this mail. We actually can’t accept patches to anything in the DLR and Ruby parser and runtime. So really the patches have to be to the libraries, or the infrastructure. We also need to…

---

## [Events?](https://www.ruby-forum.com/t/events/145899)

<div class="topic-metadata">

**Author:** [@Sean\_CSHess](https://www.ruby-forum.com/u/Sean_CSHess)\
**Replies:** 7\
**Last updated:** [August 15, 2008, 2:13pm UTC](https://www.ruby-forum.com/t/events/145899 "2008-08-15T14:13:07Z")

</div>

Hi all, Is there a built-in event system for IronRuby? I know I can handle events with button.click { }, but what if I want to dispatch my own, custom events (from a class I created myself?). I wrote my own event …

---

## [Threaded IO trouble](https://www.ruby-forum.com/t/threaded-io-trouble/145149)

<div class="topic-metadata">

**Author:** [@Michal\_S](https://www.ruby-forum.com/u/Michal_S)\
**Replies:** 12\
**Last updated:** [August 15, 2008, 1:57pm UTC](https://www.ruby-forum.com/t/threaded-io-trouble/145149 "2008-08-15T13:57:51Z")

</div>

Hello I do not understand the internals of Ruby IO but what I get here looks really awful. I am interfacing an application that processes lines of text and buffers part of the output until EOF (or EOF tag). I thought…

---

## [Second #ruby-pro gathering](https://www.ruby-forum.com/t/second-ruby-pro-gathering/145600)

<div class="topic-metadata">

**Author:** [@apeiros](https://www.ruby-forum.com/u/apeiros)\
**Replies:** 1\
**Last updated:** [August 15, 2008, 1:39pm UTC](https://www.ruby-forum.com/t/second-ruby-pro-gathering/145600 "2008-08-15T13:39:55Z")

</div>

I’m proud to announce that #ruby-pro\[1\] will be holding its second gathering\[2\] on Friday, August 15th at 23.00 UTC. The topic of the gathering will be git - tutorial, walkthrough and demo through the distributed rev…

---

## [Inconsistent regexp behavior](https://www.ruby-forum.com/t/inconsistent-regexp-behavior/145881)

<div class="topic-metadata">

**Author:** [@Glen\_H](https://www.ruby-forum.com/u/Glen_H)\
**Replies:** 6\
**Last updated:** [August 15, 2008, 11:21am UTC](https://www.ruby-forum.com/t/inconsistent-regexp-behavior/145881 "2008-08-15T11:21:47Z")

</div>

I have a script with two lines: puts “toads suck”.gsub(/(\\s)/, “\\#{$1}”) puts " a ".gsub(/(\\s), “\\#{$1}”) I get broken output for the first: toads\\suck \\ a\\ Can anyone explain why this is happening. I’m convinced …

---

## [Is it possible to extract data out of memory using Ruby?](https://www.ruby-forum.com/t/is-it-possible-to-extract-data-out-of-memory-using-ruby/145817)

<div class="topic-metadata">

**Author:** [@eterps](https://www.ruby-forum.com/u/eterps)\
**Replies:** 3\
**Last updated:** [August 15, 2008, 9:11am UTC](https://www.ruby-forum.com/t/is-it-possible-to-extract-data-out-of-memory-using-ruby/145817 "2008-08-15T09:11:36Z")

</div>

Is it possible to extract data out of memory using Ruby? Something like this: Memory.get\_byte(pos) Or something like this Perl module: Disassemble::X86::MemRegion - Represent a region of memory - metacpan.org This Pe…

---

## [Re: Noob looking for a place to start](https://www.ruby-forum.com/t/re-noob-looking-for-a-place-to-start/145938)

<div class="topic-metadata">

**Author:** [@raker\_t](https://www.ruby-forum.com/u/raker_t)\
**Replies:** 0\
**Last updated:** [August 15, 2008, 9:07am UTC](https://www.ruby-forum.com/t/re-noob-looking-for-a-place-to-start/145938 "2008-08-15T09:07:30Z")

</div>

Welcome to the group! To really answer you question I’d need to know what you’re interested in. However, in the general sense there is plenty to be done. Options for you: Hop in and help me with testing. I could use…

---

## [Use of dup to remove references](https://www.ruby-forum.com/t/use-of-dup-to-remove-references/145923)

<div class="topic-metadata">

**Author:** [@circlefusion](https://www.ruby-forum.com/u/circlefusion)\
**Replies:** 5\
**Last updated:** [August 15, 2008, 8:59am UTC](https://www.ruby-forum.com/t/use-of-dup-to-remove-references/145923 "2008-08-15T08:59:18Z")

</div>

Hello I am new to ruby and looking for a brief explanation on why a code sample works in an unexpected way. Beginning of code def wipe\_from( sentence ) sentence\_new = sentence while sentence\_new.include? ‘(’ open …

---

## [Thread pooling w/Merb vs. Rails in a JEE Web app. context](https://www.ruby-forum.com/t/thread-pooling-w-merb-vs-rails-in-a-jee-web-app-context/145795)

<div class="topic-metadata">

**Author:** [@weyus](https://www.ruby-forum.com/u/weyus)\
**Replies:** 3\
**Last updated:** [August 15, 2008, 7:08am UTC](https://www.ruby-forum.com/t/thread-pooling-w-merb-vs-rails-in-a-jee-web-app-context/145795 "2008-08-15T07:08:42Z")

</div>

It appears that there is some kind of built-in thread pooling that you get if you deploy a Rails app. into a JEE container using Goldspike or Warbler and you have a couple of parameters to set the upper and lower boun…

---

## [How can I use Berkeley DB with Ruby?](https://www.ruby-forum.com/t/how-can-i-use-berkeley-db-with-ruby/145809)

<div class="topic-metadata">

**Author:** [@strdevil](https://www.ruby-forum.com/u/strdevil)\
**Replies:** 5\
**Last updated:** [August 15, 2008, 6:55am UTC](https://www.ruby-forum.com/t/how-can-i-use-berkeley-db-with-ruby/145809 "2008-08-15T06:55:31Z")

</div>

I’m a Thai student. My teacher ordered me to use Berkeley DB in the term project. I saw in BDB website that BDB is worked with Ruby but I don’t have any idea to connect it. Anyone knows how to connect it? I’ve used my…

---

## [Is Ruby has something equivalent to ctypes in Python?](https://www.ruby-forum.com/t/is-ruby-has-something-equivalent-to-ctypes-in-python/145804)

<div class="topic-metadata">

**Author:** [@shinwoo](https://www.ruby-forum.com/u/shinwoo)\
**Replies:** 6\
**Last updated:** [August 15, 2008, 5:21am UTC](https://www.ruby-forum.com/t/is-ruby-has-something-equivalent-to-ctypes-in-python/145804 "2008-08-15T05:21:08Z")

</div>

I would like to load dll and create complex c datatype structure for the dll. This can be done with ctypes library in Python. So, do ruby has similar library like ctypes?

---

## [Tricky hash initialization](https://www.ruby-forum.com/t/tricky-hash-initialization/145913)

<div class="topic-metadata">

**Author:** [@raypereda](https://www.ruby-forum.com/u/raypereda)\
**Replies:** 5\
**Last updated:** [August 15, 2008, 1:55am UTC](https://www.ruby-forum.com/t/tricky-hash-initialization/145913 "2008-08-15T01:55:49Z")

</div>

h = Hash.new {|h,k| h\[k\] = {} } This is one level deep defaults to a fresh new hash. h = Hash.new {|h,k| h\[k\] = Hash.new{ |h2,k2| h2\[k2\] = {} } } This is two levels deep initialization to a fresh new hash. How do I t…

---

## [Silverlight and Custom Components](https://www.ruby-forum.com/t/silverlight-and-custom-components/145898)

<div class="topic-metadata">

**Author:** [@Sean\_CSHess](https://www.ruby-forum.com/u/Sean_CSHess)\
**Replies:** 3\
**Last updated:** [August 14, 2008, 11:54pm UTC](https://www.ruby-forum.com/t/silverlight-and-custom-components/145898 "2008-08-14T23:54:44Z")

</div>

Hi all, One of the first things I tried to do when I started using IronRuby with Silverlight was to separate my view components into separate components. I soon learned, to my dismay, that it was way harder than it s…

---

## [Mutithreading to implement near 7000 to 10000 mssage per min](https://www.ruby-forum.com/t/mutithreading-to-implement-near-7000-to-10000-mssage-per-min/145807)

<div class="topic-metadata">

**Author:** [@kajamohaideen\_2003](https://www.ruby-forum.com/u/kajamohaideen_2003)\
**Replies:** 9\
**Last updated:** [August 14, 2008, 11:29pm UTC](https://www.ruby-forum.com/t/mutithreading-to-implement-near-7000-to-10000-mssage-per-min/145807 "2008-08-14T23:29:33Z")

</div>

Hello, we want to process 7000 to 10000 message and store it to the Database perminute. we are trying through threads. can you please help me how we do? Regards Kaja Mohaidee.A Trichy

---

## [Code Review: warning1](https://www.ruby-forum.com/t/code-review-warning1/145909)

<div class="topic-metadata">

**Author:** [@Seo\_S](https://www.ruby-forum.com/u/Seo_S)\
**Replies:** 0\
**Last updated:** [August 14, 2008, 11:05pm UTC](https://www.ruby-forum.com/t/code-review-warning1/145909 "2008-08-14T23:05:29Z")

</div>

Attached patch fixes 4 unused local variable warnings, and possibly a bug in ExpressionTreeVisitor. For BinaryExpression node, return value of visiting node.Conversion was not passed. Isn’t that a bug? All warnings we…

---

## [Code Review: warning2](https://www.ruby-forum.com/t/code-review-warning2/145908)

<div class="topic-metadata">

**Author:** [@Seo\_S](https://www.ruby-forum.com/u/Seo_S)\
**Replies:** 0\
**Last updated:** [August 14, 2008, 10:59pm UTC](https://www.ruby-forum.com/t/code-review-warning2/145908 "2008-08-14T22:59:02Z")

</div>

Attached patch fixes 5 more unused local variable warnings. It should be uncontroversial. If some unused variable assignment is there for debugging or other purposes, I think it is advisable to write a comment saying …

---

## [Yaml and dates](https://www.ruby-forum.com/t/yaml-and-dates/145907)

<div class="topic-metadata">

**Author:** [@Shadowfirebird](https://www.ruby-forum.com/u/Shadowfirebird)\
**Replies:** 1\
**Last updated:** [August 14, 2008, 10:52pm UTC](https://www.ruby-forum.com/t/yaml-and-dates/145907 "2008-08-14T22:52:35Z")

</div>

It’s turning out to be very difficult to come up with a reliable example, but I’m having problems with dates in yaml. Sometimes they turn up in Ruby as dates, sometimes as strings. Is anyone else having this problem? …

---

## [Truncate float to 2 decimals](https://www.ruby-forum.com/t/truncate-float-to-2-decimals/145752)

<div class="topic-metadata">

**Author:** [@Junkone](https://www.ruby-forum.com/u/Junkone)\
**Replies:** 5\
**Last updated:** [August 14, 2008, 10:50pm UTC](https://www.ruby-forum.com/t/truncate-float-to-2-decimals/145752 "2008-08-14T22:50:14Z")

</div>

how do i truncate the float to 2 decimals irb(#Object:0x3d95578):001:0\> f=0.911501706632285 =\> 0.911501706632285

---

## [ScriptableMember and Silverlight](https://www.ruby-forum.com/t/scriptablemember-and-silverlight/145896)

<div class="topic-metadata">

**Author:** [@Sean\_CSHess](https://www.ruby-forum.com/u/Sean_CSHess)\
**Replies:** 3\
**Last updated:** [August 14, 2008, 10:03pm UTC](https://www.ruby-forum.com/t/scriptablemember-and-silverlight/145896 "2008-08-14T22:03:22Z")

</div>

Hello all, I need some way to either access a javascript variable or expose a function to javascript to be called later. I’ve tried option #2, with the following call, but I don’t know how to specify a member funct…

---

## [Re: IronRuby binary disribution](https://www.ruby-forum.com/t/re-ironruby-binary-disribution/145858)

<div class="topic-metadata">

**Author:** [@markbates](https://www.ruby-forum.com/u/markbates)\
**Replies:** 11\
**Last updated:** [August 14, 2008, 9:58pm UTC](https://www.ruby-forum.com/t/re-ironruby-binary-disribution/145858 "2008-08-14T21:58:39Z")

</div>

Ivan, Thanks. I tried that (I don’t have a ruby installation on the machine I’m trying this on, so I started ir with ir -I “C:\\ironruby\\lib;C:\\ironruby\\lib\\ruby\\1.8”. In the latter of those folders are all the ruby…

---

## [Problem using sqlite 3](https://www.ruby-forum.com/t/problem-using-sqlite-3/145863)

<div class="topic-metadata">

**Author:** [@reis](https://www.ruby-forum.com/u/reis)\
**Replies:** 2\
**Last updated:** [August 14, 2008, 9:57pm UTC](https://www.ruby-forum.com/t/problem-using-sqlite-3/145863 "2008-08-14T21:57:29Z")

</div>

I’m trying to build a Rails app that uses JRuby and as database back end sqlite. Now, trying to use this db engine, I’m encountering some trouble, and as I know it is still work in progress I wanted to know if I’m ma…

---

## [Db create and migrate from war](https://www.ruby-forum.com/t/db-create-and-migrate-from-war/145895)

<div class="topic-metadata">

**Author:** [@Dave\_Ray](https://www.ruby-forum.com/u/Dave_Ray)\
**Replies:** 1\
**Last updated:** [August 14, 2008, 9:08pm UTC](https://www.ruby-forum.com/t/db-create-and-migrate-from-war/145895 "2008-08-14T21:08:45Z")

</div>

Hi there. I’ve successfully packaged up my Rails app with Warbler and deploy it on Tomcat 5.5. Next, I’d like to ship it to my customer with a minimal set of installation instructions. Ideally, it would be “drop war …

---

## [Rmagick-win32 gem?](https://www.ruby-forum.com/t/rmagick-win32-gem/145890)

<div class="topic-metadata">

**Author:** [@aidy](https://www.ruby-forum.com/u/aidy)\
**Replies:** 1\
**Last updated:** [August 14, 2008, 8:00pm UTC](https://www.ruby-forum.com/t/rmagick-win32-gem/145890 "2008-08-14T20:00:14Z")

</div>

Hi, I have attempted to gem install rmagick: Being on windows I am informed that I must install rmagick-win32 gem I have browsed the gems on Rubyforge and rmagick-win32 gem is not there. Is there an alternative? Ai…

---

## [Simply\_captcha or any captcha for jruby](https://www.ruby-forum.com/t/simply-captcha-or-any-captcha-for-jruby/145879)

<div class="topic-metadata">

**Author:** [@sharkie](https://www.ruby-forum.com/u/sharkie)\
**Replies:** 2\
**Last updated:** [August 14, 2008, 7:45pm UTC](https://www.ruby-forum.com/t/simply-captcha-or-any-captcha-for-jruby/145879 "2008-08-14T19:45:28Z")

</div>

Rmagic4j will not cut it. Does someone have a suggestion on how I can get an easy captcha with JRuby? To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage\_email

---

## [Date.parse does not work anymore](https://www.ruby-forum.com/t/date-parse-does-not-work-anymore/145888)

<div class="topic-metadata">

**Author:** [@Junkone](https://www.ruby-forum.com/u/Junkone)\
**Replies:** 2\
**Last updated:** [August 14, 2008, 7:40pm UTC](https://www.ruby-forum.com/t/date-parse-does-not-work-anymore/145888 "2008-08-14T19:40:10Z")

</div>

i am sure i have used date.parse in my code. however it does not work anymore. i also tried to change the string format but it did not help. any assistance is appreciated. irb(main):022:0\> Date.parse(“2006-01-02”) No…

---

## [Uninitialized constant: String::StringIO](https://www.ruby-forum.com/t/uninitialized-constant-string-stringio/145880)

<div class="topic-metadata">

**Author:** [@lynchnco](https://www.ruby-forum.com/u/lynchnco)\
**Replies:** 5\
**Last updated:** [August 14, 2008, 7:23pm UTC](https://www.ruby-forum.com/t/uninitialized-constant-string-stringio/145880 "2008-08-14T19:23:30Z")

</div>

Hi, I’m having a hard time spotting my bug in this code. When it runs it gives me: uninitialized constant String::StringIO (NameError) Am I missing something? StringIO is a global constant. Why can’t ruby find it? c…

---

## [Logging 0.9.1 (Green Eggs & Ham)](https://www.ruby-forum.com/t/logging-0-9-1-green-eggs-ham/145883)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [August 14, 2008, 7:07pm UTC](https://www.ruby-forum.com/t/logging-0-9-1-green-eggs-ham/145883 "2008-08-14T19:07:17Z")

</div>

logging version 0.9.1 by Tim P. http://logging.rubyforge.org/ (the “Green Eggs & Ham” release) == DESCRIPTION Logging is a flexible logging library for use in Ruby programs based on the design of Java’s log4j libr…

---

## [Documenting DSLs](https://www.ruby-forum.com/t/documenting-dsls/145560)

<div class="topic-metadata">

**Author:** [@tcsnide](https://www.ruby-forum.com/u/tcsnide)\
**Replies:** 9\
**Last updated:** [August 14, 2008, 6:20pm UTC](https://www.ruby-forum.com/t/documenting-dsls/145560 "2008-08-14T18:20:52Z")

</div>

Hey, has anyone thought about or worked on a “next gen” documentation system for handling Ruby DSLs? I have some code that I’d really like to DSLify, but I don’t want to loose the RDocs. Let me give a simple example. …

[Previous page](https://www.ruby-forum.com/c/ruby/7.md?page=1045)

[Next page](https://www.ruby-forum.com/c/ruby/7.md?page=1047)
