[odb-users] schema evolution, changelog xml and output .sql

Boris Kolpackov boris at codesynthesis.com
Wed Aug 30 02:04:52 EDT 2023


MM <finjulhich at gmail.com> writes:

> When building and no change in the pair OldDate,NewDate, then the odb run
> doesn't change the changelog xml files and no sql files are changed.
> 
> However, when I've changed the C++ classes or the odb pragmas, I then
> change NewDate as OldDate and use today as NewDate. That odb run then
> updates the changelog xml and the sql files.
> 
> As part of the cmake based build system, can I examine the odb exit code to
> see which situation I'm in?

No, currently the ODB compiler does not distinguish between these two
situations with an exist code. But we could probably add this support
if really needed.

Though it feels like it should be just as easy to detect this by
comparing the changelog file modification times before/after or,
alternatively, hashing the changelog file contents and comparing
that, if you want a more robust mechanism.



More information about the odb-users mailing list