Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6226353
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T09:00:49+00:00 2026-05-24T09:00:49+00:00

I have a problem generated by rails… My mysql db saves the dates in

  • 0

I have a problem generated by rails…

My mysql db saves the dates in this format:

2011-08-05 14:07:24 +0200

This kind of date gets generated by the created_at function:

When I use the Time.now function, the format is:

Fri Aug 05 14:07:24 +0200 2011

Unfortunately those two dates are not compatible for mysql…

Thanks for your help

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T09:00:50+00:00Added an answer on May 24, 2026 at 9:00 am

    How do you pass your time variable to the model? If you pass like Time.now as a Time object then Rails converts the format to the correct SQL format.

    So do not pass it as a String

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this is probably a very basic question. I have installed rails 3 and generated
I have a problem while pasting my contents (or text) generated by Java code
I have problem compilin this code..can anyone tell whats wrong with the syntax CREATE
I am seeing this somehow odd problem (even though I have the feeling I
I have a Problem in my Rails application. I've left everything at standard Rails
I have a problem with schema.rb in Rails. If i run rake db:migrate the
I have just begun Rails 3. I have generated the below code using the
I recently ran into this problem: Rails 3 link_to (:method => :delete) not working
I'm using Rails 3, with devise and have generated the devise views. Recently I've
I couldn't find anyone else with this problem so I thought I'd ask. rails

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.