Files
Stefan 10ecdfa2e4 Add Fuchs_Database SSDT project (schema source of truth)
Adds the SQL Server Data Tools project for the fuchs_fds database — tables,
table types, functions and stored procedures that the backend calls (e.g.
fds__getInvoice, fds__merge_bankingtransactions, fds__tt__bankingtransactions,
fds__admin_getReportCatalog, fis_* auth). Build/model caches (bin, obj,
*.dbmdl, *.jfm, *.user) are git-ignored.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-05 14:50:54 +02:00

30 lines
1.1 KiB
Transact-SQL

CREATE TABLE [dbo].[mfr__appointments] (
[Id] BIGINT NOT NULL,
[Version] INT NOT NULL,
[State] NVARCHAR (255) NULL,
[Type] NVARCHAR (255) NULL,
[EndDateTime] DATETIME NULL,
[StartDateTime] DATETIME NOT NULL,
[DrivingDistanceFrom] INT NULL,
[DrivingDistanceTo] INT NULL,
[WasReadOnClientSide] BIT NOT NULL,
[ContactIds] VARCHAR (MAX) NULL,
[ServiceRequestId] BIGINT NOT NULL,
[ContactId] BIGINT NOT NULL,
[Note] NVARCHAR (MAX) NULL,
CONSTRAINT [PK_mfr__appointment] PRIMARY KEY CLUSTERED ([Id] ASC)
);
GO
CREATE NONCLUSTERED INDEX [mfr__appointments__ix2]
ON [dbo].[mfr__appointments]([State] ASC, [ServiceRequestId] ASC)
INCLUDE([EndDateTime], [StartDateTime]);
GO
CREATE NONCLUSTERED INDEX [mfr__appointments__ix1]
ON [dbo].[mfr__appointments]([State] ASC)
INCLUDE([EndDateTime], [StartDateTime], [ServiceRequestId]);