rails-sqlserver / activerecord-sqlserver-adapter

SQL Server Adapter For Rails
MIT License
972 stars 558 forks source link

Fix precision handling in time migration #1144

Closed kiyot closed 8 months ago

kiyot commented 9 months ago

Resolved an issue where creating a time column with a precision of 7 would trigger the following error.

ArgumentError: No time type has precision of 7. The allowed range of precision is from 0 to 6 (ArgumentError)

aidanharan commented 8 months ago

@kiyot Thanks for the PR. I made a small change so that I let the database handle the default precision by sending time to it instead of time(7).