MSSQL connector fails to preview or import tables containing a `TIMESTAMP`/`ROWVERSION` column
I maintainer di solito rispondono entro 2 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- Mezza giornata
- Idoneità per principianti
- 75/100
Direzione di ricerca
Locate the MSSQL connector code that generates SELECT queries for table preview and import. The error shows the connector implicitly converts TIMESTAMP/ROWVERSION to nvarchar(max), which SQL Server forbids. Modify the query generation to handle this data type—cast to VARBINARY or skip the conversion. Test with the reproduction table to confirm the fix.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Environment
- Microsoft Data Formulator running in Docker
- Ubuntu Server 24.04
- Microsoft SQL Server 2022
- MSSQL Python driver (
mssql_python, as shown in the application log)
Description
When I try to preview or import a SQL Server table that contains a TIMESTAMP column, the operation fails. In SQL Server, TIMESTAMP is a synonym for ROWVERSION—it stores a binary row version, not a date or time.
Minimal reproduction
CREATE TABLE dbo.Repro (
Id int NOT NULL PRIMARY KEY,
RowVersionColumn timestamp NOT NULL,
SysStartTime datetime2(7) GENERATED ALWAYS AS ROW START NOT NULL,
SysEndTime datetime2(7) GENERATED ALWAYS AS ROW END NOT NULL,
PERIOD FOR SYSTEM_TIME (SysStartTime, SysEndTime)
)
WITH (
SYSTEM_VERSIONING = ON (
HISTORY_TABLE = dbo.ReproHistory
)
);
- Connect Data Formulator to the SQL Server database.
- Select
dbo.Repro. - Try to preview or import the table.
Expected behavior
The table should be previewed and imported successfully, with the ROWVERSION column handled as binary data or otherwise handled safely.
Actual behavior
Both preview and import fail with a data-load error. The SQL Server driver reports:
Invalid character value for cast specification;
[Microsoft][SQL Server] Explicit conversion of the timestamp data type
to nvarchar(max) is not allowed.
The error occurs while executing the generated SELECT query.
- Lingua principale
- Python
- Stelle
- 17.7k
- Fork
- 1.7k
- Merge medio
- 4g 1h
- PR unite (30g)
- 8
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoft/data-formulator
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
microsoft/data-formulator#513 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
microsoft/data-formulator#520 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 58/100
microsoft/data-formulator#519 ·
I maintainer di solito rispondono entro 2 giorni
-
Data table is emptyAperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 50/100
microsoft/data-formulator#518 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 52/100
microsoft/data-formulator#517 ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di microsoft/data-formulator
Issue simili
-
cli good first issue help wanted python up-for-grabs
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
andrewsiah/agentswarm-data-tasks#36 ·
I maintainer di solito rispondono entro 1 giorno
-
bug drawing-tools
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
cofade/open-garden-planner#827 ·
I maintainer di solito rispondono entro 1 giorno
-
Methodology pageApertadocumentation site texts
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
Krasnopjorovs/temet#66 ·
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno