Files
turso/core
Jussi Saurio 0d37ac2519 Merge 'translate: couple fixes from testing with Gorm' from Preston Thorpe
Ongoing tests for [turso-go](https://github.com/tursodatabase/turso-go)
have unearthed a couple more issues
closes #3187
### Number 1:
We were getting something like:
```sql
sqlite_autoindex_`databases`_2
```
when creating autoindex for table in Gorm (gorm is notorious for
backticks everywhere), because of not normalizing the column name when
creating autoindex.
### Number 2:
When creating table with `PRIMARY KEY AUTOINCREMENT`, we were still
creating the index, but it wasn't properly handled in
`populate_indices`, because we are doing the following:
```rust
                if column.primary_key && unique_set.is_primary_key {
                    if column.is_rowid_alias {
                        // rowid alias, no index needed
                        continue; // continues, but doesn't consume it..
                    }
```
So if we created such an index entry for the AUTOINCREMENT... we would
trip this:
```rust
assert!(automatic_indexes.is_empty(), "all automatic indexes parsed from sqlite_schema should have been consumed, but {} remain", automatic_indexes.len());
```

Reviewed-by: Jussi Saurio <jussi.saurio@gmail.com>

Closes #3186
2025-09-18 09:21:41 +03:00
..
2025-09-15 14:48:26 +03:00
2025-09-17 12:18:44 +02:00
2025-06-30 10:01:03 +03:00
2025-08-15 17:08:53 -04:00
2025-01-28 14:55:38 -05:00
2025-09-13 11:00:37 +05:30
2025-06-23 19:52:13 +01:00
2025-09-17 11:57:23 +03:00
2025-01-28 14:55:38 -05:00
2025-06-23 19:52:13 +01:00
2025-09-17 12:46:55 +03:00
2025-09-13 10:49:14 +02:00
2025-09-17 15:53:06 -04:00
2025-06-30 09:54:13 +03:00