activerecord-sqlserver-adapter
activerecord-sqlserver-adapter copied to clipboard
TinyTds::Error: Type T_FK is not a defined system type.
Rails version 6 multi database using
for example if run db:rollback got error:
--trace log
** Invoke db:rollback (first_time)
** Invoke db:load_config (first_time)
** Invoke environment (first_time)
** Execute environment
** Execute db:load_config
** Execute db:rollback
== 20200810025414 AddDescriptionToOrders: reverting ===========================
-- remove_column(:orders, :description, :string)
-> 0.0017s
== 20200810025414 AddDescriptionToOrders: reverted (0.0026s) ==================
** Invoke db:_dump (first_time)
** Execute db:_dump
** Invoke db:schema:dump (first_time)
** Invoke db:load_config
** Execute db:schema:dump
rails aborted!
ActiveRecord::StatementInvalid: TinyTds::Error: Type T_FK is not a defined system type
```.
other databases is normal dumped after db:migration and db:rollback
this error got also if run
rails db:migrate:down:primary VERSION=123123123
i think sql adapter has bug on dumping command
FREETDS version
tsql -C
Compile-time settings (established with the "configure" script)
Version: freetds v1.1.24
freetds.conf directory: /usr/local/etc
MS db-lib source compatibility: no
Sybase binary compatibility: no
Thread safety: yes
iconv library: yes
TDS version: 7.3
iODBC: no
unixodbc: yes
SSPI "trusted" logins: no
Kerberos: no
OpenSSL: yes
GnuTLS: no
MARS: yes