On Aug 30, 9:07 am, sol <[email protected]> wrote:
> I found out with sqlite's 'dump' why it does not work, here is the
> full thing:
>
> https://gist.github.com/9fa01f6d150c3be6bd04
>
> it seems its in a different representation, now I am not sure if this
> is a rails bug or what to do with it
>
That byte sequence is in fact exactly the same as 127.0.0.1 (if you
encoding is ascii or anything that agrees with ascii for the lower 7
bits). For me this points at an encoding problem, but I'm not sure why
this would happen. You might try sticking some breakpoints in the
active record code to see what the difference is (or check if the ruby
encoding of the two strings you have differ)

Fred
> On 30 Aug., 09:17, Alexey Muranov <[email protected]> wrote:
>
>
>
>
>
>
>
> > I am sorry, Christoph, but from your post it is not clear, how you
> > create a record with :ip =>request.remote_ip
>
> > You probably cannot do this in console (request.remote_ipnot defined),
> > so you'll have to test it all in controller.
>
> > Can you do it in 3 steps:
> > create two records in the database (with a string and 
> > withrequest.remote_ip),
> > see what is in the database,
> > verify that the records look identical, but find_by_ip returns only one?
>
> > This is what i would do.
>
> > Alexey.
>
> > --
> > Posted viahttp://www.ruby-forum.com/.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to