SQLServer y fechas en W2000

Tengo uan aplicación en desarrollo sobre
W2000,
ruby 1.8.2 (2004-12-25) [i386-mswin32]
Rails 1.1.4
C:\Wrk\www\O2K7>“c:\ruby\bin\ruby.exe” “c:\ruby\bin\gem” -v
0.8.10

mas las siguientes gemas:
C:\Wrk\www\O2K7>gem list

C:\Wrk\www\O2K7>“c:\ruby\bin\ruby.exe” “c:\ruby\bin\gem” list

*** LOCAL GEMS ***

actionmailer (1.2.3, 1.2.1)
Service layer for easy email delivery and testing.

actionpack (1.12.3, 1.12.1)
Web-flow and rendering framework putting the VC in MVC.

actionwebservice (1.1.4, 1.1.2)
Web service support for Action Pack.

activerecord (1.14.3, 1.14.2)
Implements the ActiveRecord pattern for ORM.

activesupport (1.3.1)
Support and utility classes used by the Rails framework.

auth_generator (1.5.3)
[Rails] Auth generator.

fxri (0.3.2)
Graphical interface to the RI documentation, with search engine.

fxruby (1.2.6)
FXRuby is the Ruby binding to the FOX GUI toolkit.

rails (1.1.4, 1.1.2)
Web-application framework with template engine, control-flow layer,
and ORM.

rake (0.7.1)
Ruby based make-like utility.

RMagick-win32 (1.9.2)
RMagick is an interface between the Ruby programming language and
the ImageMagick and GraphicsMagick image processing libraries.

rubyscript2exe (0.4.2)
A Ruby Compiler

sources (0.0.1)
This package provides download sources for remote gem installation

tar2rubyscript (0.4.8)
A Tool for Distributing Ruby Applications

mi problema : Al guardar una fecha me da lo siguiente :

DBI::DatabaseError: Execute
OLE error code:80040E07 in Microsoft OLE DB Provider for SQL Server
La conversi�n del tipo de datos char a datetime produjo un valor
datetime fuera de intervalo.
HRESULT error code:0x80020009

  Ocurri� una excepci�n.: INSERT INTO users ([salt], [updated_at],

[crypted_password], [remember_token_expires_at], [remember_token],
[login], [created_at], [email])
VALUES(‘3316ac534f2d05f2802d8b15170cc6e76522b8ac’, ‘2007-02-20
23:38:36’, ‘625e109cfaa205a70344ec41e83a821a73bef72c’, NULL, NULL,
‘ampino’, ‘2007-02-20 23:38:36’, ‘[email protected]’)

RAILS_ROOT: ./script/…/config/…
Application Trace | Framework Trace | Full Trace

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/abstract_adapter.rb:120:in
log' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/sqlserver_adapter.rb:279:ininsert’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1739:in
create_without_callbacks' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:261:increate_without_timestamps’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/timestamp.rb:30:in
create' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1718:increate_or_update_without_callbacks’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:249:in
create_or_update' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1392:insave_without_validation’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:724:in
save_without_transactions' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:91:intransaction’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:118:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1398:in
save_without_validation!' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:734:insave!’
#{RAILS_ROOT}/app/controllers/account_controller.rb:29:in `signup’

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/abstract_adapter.rb:120:in
log' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/sqlserver_adapter.rb:279:ininsert’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1739:in
create_without_callbacks' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:261:increate_without_timestamps’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/timestamp.rb:30:in
create' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1718:increate_or_update_without_callbacks’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:249:in
create_or_update' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1392:insave_without_validation’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:724:in
save_without_transactions' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:91:intransaction’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:118:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1398:in
save_without_validation!' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:734:insave!’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:910:in
send' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:910:inperform_action_without_filters’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/filters.rb:368:in
perform_action_without_benchmark' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:in
measure' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/rescue.rb:82:in
perform_action' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:381:insend’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:381:in
process_without_filters' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/filters.rb:377:inprocess_without_session_management_support’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/session_management.rb:117:in
process' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/dispatcher.rb:38:indispatch’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:115:in
handle_dispatch' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:81:inservice’
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:inrun’
c:/ruby/lib/ruby/1.8/webrick/server.rb:155:in start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:144:instart’
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:94:instart’
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in each' c:/ruby/lib/ruby/1.8/webrick/server.rb:89:instart’
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:79:instart’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:67:in
dispatch' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/commands/servers/webrick.rb:59 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:inrequire__’
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
require' c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:inrequire’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/commands/server.rb:30
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
require__' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:inrequire’
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
`require’
script/server:3

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/abstract_adapter.rb:120:in
log' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/connection_adapters/sqlserver_adapter.rb:279:ininsert’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1739:in
create_without_callbacks' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:261:increate_without_timestamps’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/timestamp.rb:30:in
create' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1718:increate_or_update_without_callbacks’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/callbacks.rb:249:in
create_or_update' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1392:insave_without_validation’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:724:in
save_without_transactions' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:91:intransaction’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:118:in
transaction' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/transactions.rb:126:insave’
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/base.rb:1398:in
save_without_validation!' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:734:insave!’
#{RAILS_ROOT}/app/controllers/account_controller.rb:29:in signup' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:910:insend’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:910:in
perform_action_without_filters' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/filters.rb:368:inperform_action_without_benchmark’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:in
perform_action_without_rescue' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:inmeasure’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/benchmarking.rb:69:in
perform_action_without_rescue' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/rescue.rb:82:inperform_action’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:381:in
send' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/base.rb:381:inprocess_without_filters’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/filters.rb:377:in
process_without_session_management_support' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.12.3/lib/action_controller/session_management.rb:117:inprocess’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/dispatcher.rb:38:in
dispatch' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:115:inhandle_dispatch’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:81:in
service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:inservice’
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in run' c:/ruby/lib/ruby/1.8/webrick/server.rb:155:instart_thread’
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:144:instart_thread’
c:/ruby/lib/ruby/1.8/webrick/server.rb:94:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:89:ineach’
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:79:instart’
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in start' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/webrick_server.rb:67:indispatch’
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/commands/servers/webrick.rb:59
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
require__' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:inrequire’
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
require' c:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.4/lib/commands/server.rb:30 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:inrequire__’
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
require' c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:inrequire’
script/server:3

El pc donde esta SQLSerevr esta seteado con configuracion regional en
Español(Chile)

Al hacer las pruebas en SQL directamente la soución sería cambiar el
formato de la fecha a dd-mm-aaaa hh:mm:ss, como hago eso en Rails?

Gracias

Angel Mauricio Pino G
[email protected]
Movil: 08-577.92.72

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs