Home > Blockchain >  DBEAVER not showing SQL Server clustered index in DDSL
DBEAVER not showing SQL Server clustered index in DDSL

Time:12-20

I am having the following issue in DBEAVER 21.2.4 and SQL Server 2019 (v15.0.4178.1).

Whenever I see the DDL from SQL Server (Script Table > Create as), it displays the whole constraints:

...
    CONSTRAINT [PK_Emp] PRIMARY KEY CLUSTERED 
    (
        [EmpID] ASC
    )
        WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, 
              IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, 
              ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 100, 
              OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
    ) ON [PRIMARY]

While DBEAVER displays only

...
    CONSTRAINT PK_Emp PRIMARY KEY (EmpID)

and no data in constraints.

Not clustered. not Pad_index, nothing.

No Constraints

Is this a bug in Dbeaver, or am I missing something?

CodePudding user response:

This

 CONSTRAINT [PK_Emp] PRIMARY KEY CLUSTERED 
(
    [EmpID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 100, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]

and

CONSTRAINT PK_Emp PRIMARY KEY (EmpID)

are identical, because CLUSTERED is the default for PRIMARY KEY constraints, [PRIMARY] is the default filegroup, ALLOW_PAGE_LOCKS defaults to ON, etc.

SSMS always explicitly scripts each option, and apparantely dbbeaver omits opions that it thinks are using the default values.

  • Related