go-testfixtures / testfixtures

Ruby on Rails like test fixtures for Go. Write tests against a real database
https://pkg.go.dev/github.com/go-testfixtures/testfixtures/v3?tab=doc
MIT License
1.12k stars 80 forks source link

Make SQL work with case-sensitivie SQLServer #182

Closed wxiaoguang closed 9 months ago

wxiaoguang commented 10 months ago

In a SQLServer database with case-sensitive collation:

> select * from information_schema.tables;
SQL Error [208] [S0002]: Invalid object name 'information_schema.tables'.

> select * from INFORMATION_SCHEMA.TABLES where table_type='...';
(ok)
> select * from SYS.IDENTITY_COLUMNS;
SQL Error [208] [S0002]: Invalid object name 'SYS.IDENTITY_COLUMNS'.

> select * from sys.identity_columns;
(ok)
puni9869 commented 10 months ago

Is this change is restricted to sql server version?

wxiaoguang commented 10 months ago

Is this change is restricted to sql server version?

No

wxiaoguang commented 9 months ago

Hi @andreynering, is there any interest in this fix? Indeed it is a bug ....

andreynering commented 9 months ago

Thanks @wxiaoguang! And sorry for the wait. I'll make a release still today.