activerecord-sqlserver-adapter 7.1.5 → 7.1.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +2 -2
- data/CHANGELOG.md +12 -0
- data/README.md +1 -1
- data/VERSION +1 -1
- data/lib/active_record/connection_adapters/sqlserver/schema_statements.rb +3 -1
- data/test/cases/schema_dumper_test_sqlserver.rb +4 -0
- data/test/cases/schema_test_sqlserver.rb +4 -0
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eb26ce0a56d756f8e9ba1d571ab3f3b6ce092ac3c86f8b37bce56942ec96c485
|
4
|
+
data.tar.gz: efa5adca77b15a3c5b25c216b1b63d311a1fbfbc5ab79186d94f1b4f9a6ecedb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bfc66070966a026f6f1b42bf1c87e48ad9e0d044ce01755eeddbcbc71f2b5cabd8cd395dc9ebfa0aa1e92c5b8f4c524ead92d1abf017b907de774f224c0c02a
|
7
|
+
data.tar.gz: 9ebcf4c64077e0fdfac80b7f5ca6fc5b6218251f378dd6f61c3fcbfd48e4196a93fc09a5de87048834f1e96f3b839ddd2e0ec61457da081bf3f20fd5d5fed08c
|
data/.github/workflows/ci.yml
CHANGED
@@ -23,7 +23,7 @@ jobs:
|
|
23
23
|
uses: actions/checkout@v2
|
24
24
|
|
25
25
|
- name: Build docker images
|
26
|
-
run: docker
|
26
|
+
run: docker compose build --build-arg TARGET_VERSION=${{ matrix.ruby }}
|
27
27
|
|
28
28
|
- name: Run tests
|
29
|
-
run: docker
|
29
|
+
run: docker compose run ci
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,15 @@
|
|
1
|
+
## v7.1.7
|
2
|
+
|
3
|
+
#### Fixed
|
4
|
+
|
5
|
+
- [#1210](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/pull/1210) Handle blank SQL when parsing table name
|
6
|
+
|
7
|
+
## v7.1.6
|
8
|
+
|
9
|
+
#### Fixed
|
10
|
+
|
11
|
+
- [#1208](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/pull/1208) Exclude "guest" schema in schema dumper
|
12
|
+
|
1
13
|
## v7.1.5
|
2
14
|
|
3
15
|
#### Added
|
data/README.md
CHANGED
@@ -14,7 +14,7 @@ Interested in older versions? We follow a rational versioning policy that tracks
|
|
14
14
|
| Adapter Version | Rails Version | Support | Branch |
|
15
15
|
|-----------------|---------------|---------|--------------------------------------------------------------------------------------------------|
|
16
16
|
| Unreleased | `7.2.x` | In Development | [main](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/main) |
|
17
|
-
| `7.1.
|
17
|
+
| `7.1.7` | `7.1.x` | Active | [7-1-stable](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/7-1-stable) |
|
18
18
|
| `7.0.7` | `7.0.x` | Active | [7-0-stable](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/7-0-stable) |
|
19
19
|
| `6.1.3.0` | `6.1.x` | Active | [6-1-stable](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/6-1-stable) |
|
20
20
|
| `6.0.3` | `6.0.x` | Ended | [6-0-stable](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/6-0-stable) |
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
7.1.
|
1
|
+
7.1.7
|
@@ -400,7 +400,7 @@ module ActiveRecord
|
|
400
400
|
FROM sys.schemas
|
401
401
|
WHERE
|
402
402
|
name NOT LIKE 'db_%' AND
|
403
|
-
name NOT IN ('INFORMATION_SCHEMA', 'sys')
|
403
|
+
name NOT IN ('INFORMATION_SCHEMA', 'sys', 'guest')
|
404
404
|
SQL
|
405
405
|
|
406
406
|
query_values(sql, "SCHEMA")
|
@@ -673,6 +673,8 @@ module ActiveRecord
|
|
673
673
|
|
674
674
|
# Parses the raw table name that is used in the SQL. Table name could include database/schema/etc.
|
675
675
|
def get_raw_table_name(sql)
|
676
|
+
return if sql.blank?
|
677
|
+
|
676
678
|
s = sql.gsub(/^\s*EXEC sp_executesql N'/i, "")
|
677
679
|
|
678
680
|
if s.match?(/^\s*INSERT INTO.*/i)
|
@@ -167,6 +167,10 @@ class SchemaDumperTestSQLServer < ActiveRecord::TestCase
|
|
167
167
|
|
168
168
|
# Only generate non-default schemas. Default schema is 'dbo'.
|
169
169
|
assert_not_includes generated_schema, 'create_schema "dbo"'
|
170
|
+
assert_not_includes generated_schema, 'create_schema "db_owner"'
|
171
|
+
assert_not_includes generated_schema, 'create_schema "INFORMATION_SCHEMA"'
|
172
|
+
assert_not_includes generated_schema, 'create_schema "sys"'
|
173
|
+
assert_not_includes generated_schema, 'create_schema "guest"'
|
170
174
|
assert_includes generated_schema, 'create_schema "test"'
|
171
175
|
assert_includes generated_schema, 'create_schema "test2"'
|
172
176
|
|
@@ -66,6 +66,10 @@ class SchemaTestSQLServer < ActiveRecord::TestCase
|
|
66
66
|
it do
|
67
67
|
assert_equal "[WITH - SPACES$DOLLAR]", connection.send(:get_raw_table_name, "SELECT id FROM [WITH - SPACES$DOLLAR]")
|
68
68
|
end
|
69
|
+
|
70
|
+
it do
|
71
|
+
assert_nil connection.send(:get_raw_table_name, nil)
|
72
|
+
end
|
69
73
|
end
|
70
74
|
|
71
75
|
describe 'INSERT statements' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-sqlserver-adapter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.1.
|
4
|
+
version: 7.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ken Collins
|
@@ -15,7 +15,7 @@ authors:
|
|
15
15
|
autorequire:
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
|
-
date: 2024-
|
18
|
+
date: 2024-08-01 00:00:00.000000000 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: activerecord
|
@@ -240,8 +240,8 @@ licenses:
|
|
240
240
|
- MIT
|
241
241
|
metadata:
|
242
242
|
bug_tracker_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/issues
|
243
|
-
changelog_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/blob/v7.1.
|
244
|
-
source_code_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/v7.1.
|
243
|
+
changelog_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/blob/v7.1.7/CHANGELOG.md
|
244
|
+
source_code_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/v7.1.7
|
245
245
|
post_install_message:
|
246
246
|
rdoc_options: []
|
247
247
|
require_paths:
|