Any way to programmatically validate a groups of schema files?

We validate our schemas files by hand and there’s so many to check. Which is the recommended way to validate that from command line or if theres some function to call and check the log result will be great.

Best regards.

The basic APIs should probably be all available (certainly the classes to load a schema at runtime, of not the actual logic that does the checks). I’ll check with the team of we can migrate the latter part from DASM down into the (.NET) core library, if its not there already.


1 Like

If you will put your ands theres will be great have a way to COMPARE schemas. The actual xml use an incremental number for fields. Because that, comparing file to file is practically impossible.For that reason will be great if theres a method to compare two schemas.

Best regards.

Yeah, I always hated that, it’s a bit of a relic from the days when schemas were streamed down using Delphi’s component serialization infrastructure back in DA1.

I’m wondering if we could/should introduce a new, more diffable and unman redable/editable schema format (as option, of course)

1 Like

I dream with that! :heart_eyes: :grin:

Thanks, logged as bugs://83685

Thanks, logged as bugs://83702

see Data Abstract for Delphi vNext: New features

That remain in analysis?

Well, I logged the feature request a mere 6 days ago…

1 Like

I plan to deliver a Delphi console app to use the api and validate schema files at customer side. Which are the prerequisites on the customer machine?

The validation from the api down work on Linux. Get a system 14 error. Have sense. Theres any alternative at this moment or maybe when yo migrate to .NET core? I confirm using wine works.

Any comment will be appreciated

Bets regards.

The older schema modeler have a section storing relationships. But that relationships seems not to be checked when validate schemas. Is possible to add a way to validate that relationships( and I mena FK and PK)

Can be cool to check if some index or constraint fails to create for any reason.

Best regards.


Looks like DASM3 hadn’t validation of relationships. as a result, TDASchemaChecker also hasn’t them.

Thanks, logged as bugs://83844

Another request, to remain in the same topic. Validation seems like opening data tables and bring all the records. I compare the time for validation with little databases, taking a few minutes only, and databases with 4 million records, by example, and take hours.

In the pass we use limit for that queries as parameter but now as is managed for max records is not needed.

Will be a good idea limit the validation to x records ? I mean 1, 10, 100, not more data. If that can be configurable for all the schema also I acceptable.

I automatice the validation after update a database schema but I hit the ground with that problem.

Let me know, thanks!

Bets regards.


we can add DynamicWhere condition like 1=0, but it won’t work for tables that haven’t {WHERE} macro …
Will add comment to #83844

Still have a solution for that, opening only a record when validate schemas. Theres a suggestion with the databastract release or theres changes you must do in the library?

Please let me know.

Bets regards


this issue wasn’t touched yet because we have other issues with higher priority.

I see. but for me is really a priority. Can please give me some ideas on now to solve on my side?

I just need the validation open 1 records, not full table.

Best regards.


you can generate select SQL with TDAQueryBuilder.GenerateSelectSQL method instead of hardcoded string in TDASchemaChecker.CheckDataset.
don’t forget to specify MaxRecord = 1 - it will allow to use FIRST/TOP/LIMIT/ROWS keywords if your DB supports it