Right now if you try to create any compound index for core store dynamic model you will receive syntax error. This because "-" is prohibited and caused syntax error. For instance, for Dog model in DynamicModelTests.swift you will receive this error:
near "-": syntax error in "CREATE INDEX IF NOT EXISTS Z_Dog__CoreStoreSchema_indexes_Dog_age-nickname ON ZANIMAL (ZAGE COLLATE BINARY ASC, ZNICKNAME COLLATE BINARY ASC)
Let's use "_" instead.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/JohnEstropia/CoreStore/pull/421
**Author:** [@xquezme](https://github.com/xquezme)
**Created:** 4/5/2021
**Status:** ✅ Merged
**Merged:** 7/20/2021
**Merged by:** [@JohnEstropia](https://github.com/JohnEstropia)
**Base:** `develop` ← **Head:** `develop`
---
### 📝 Commits (1)
- [`6a23940`](https://github.com/JohnEstropia/CoreStore/commit/6a2394052c93641f61bf12a4e8023b76529ae307) fix compound indexes for dynamic models
### 📊 Changes
**2 files changed** (+2 additions, -2 deletions)
<details>
<summary>View changed files</summary>
📝 `CoreStoreTests/DynamicModelTests.swift` (+1 -1)
📝 `Sources/CoreStoreSchema.swift` (+1 -1)
</details>
### 📄 Description
Right now if you try to create any compound index for core store dynamic model you will receive syntax error. This because "-" is prohibited and caused syntax error. For instance, for `Dog` model in `DynamicModelTests.swift` you will receive this error:
```
near "-": syntax error in "CREATE INDEX IF NOT EXISTS Z_Dog__CoreStoreSchema_indexes_Dog_age-nickname ON ZANIMAL (ZAGE COLLATE BINARY ASC, ZNICKNAME COLLATE BINARY ASC)
```
Let's use "_" instead.
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/JohnEstropia/CoreStore/pull/421
Author: @xquezme
Created: 4/5/2021
Status: ✅ Merged
Merged: 7/20/2021
Merged by: @JohnEstropia
Base:
develop← Head:develop📝 Commits (1)
6a23940fix compound indexes for dynamic models📊 Changes
2 files changed (+2 additions, -2 deletions)
View changed files
📝
CoreStoreTests/DynamicModelTests.swift(+1 -1)📝
Sources/CoreStoreSchema.swift(+1 -1)📄 Description
Right now if you try to create any compound index for core store dynamic model you will receive syntax error. This because "-" is prohibited and caused syntax error. For instance, for
Dogmodel inDynamicModelTests.swiftyou will receive this error:Let's use "_" instead.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.