This post has been republished via RSS; it originally appeared at: Microsoft Tech Community - Latest Blogs - .
Kusto allows you to very quickly get productive. You can setup an ingestion pipeline in minutes that will ingest Terabytes (TBs) of data per day.
Like any piece of code, your database schema is as good as the intent you convey when you wrote it. But over time, the intent diffuses and different priorities, authors and just plain miscommunication can diminish the quality of your code.
The new Kusto command .show database schema violations was designed to validate the current state of your database schema and find inconsistencies.
- Does the function associated with an update policy still have the same schema as the target schema or did the two drift away?
- Function A calls Function B which calls Function C: does Function B still exists? are the schema of each output chain in a consistent manner?
- Does your materialized view source table still exists? Is the schema compatible?
The command returns a table with schema validation issues. Since that is a Kusto result set, you could filter / format it using usual Kusto query capacity.
You can use this command for a spot check on your database. You could also use it in a CI/CD automation: for instance, you could validate your schema in a dev environment before deploying the schema to production, as a quality gate.
The command is even integrated in the Kusto.Explorer Windows client in the database context menu for even easier access:
We hope this will help you raise the bar in quality on your database and make you & your Kusto team more productive in the long run!