Skip to content

[Bug] When database name is empty it generates wrong sql query #1604

@rohkhann

Description

@rohkhann

For databases like datamart that are mssql, databasename is emtpy from the connection string.

In sql metadataprovider, during initialize async the tableprefix is creating using databasename:
selectCommand.CommandText
= $"SELECT * FROM {tablePrefix}.{SqlQueryBuilder.QuoteIdentifier(tableName)}";

if databasename is empty then the tableprefix generated is [].[dbo].[books] for a sample table books with dbo schema which results in sql query issue.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions