syncing-diva-sql

Synchronize SQL Server schemas from compiled Divalto dictionaries and parse synchronization reports.

6|Updated May 11, 2026
One-click install
npx skills add https://github.com/divalto/divalto-ia-devkit --skill syncing-diva-sql-divalto
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: syncing-diva-sql
Source: https://github.com/divalto/divalto-ia-devkit/tree/main/plugins/divalto-devkit/skills/syncing-diva-sql
Command: npx skills add https://github.com/divalto/divalto-ia-devkit --skill syncing-diva-sql-divalto

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? After compiling a Divalto project with buildall, the SQL Server database schema must be updated to match the compiled dictionaries, and the synchronization report must be checked for errors. This Skill automates running xwin7 synchroauto with the correct prerequisites and parses the resulting report so failures are diagnosed quickly. ## Core Features & Use Cases - Automated SQL synchronization: Runs xwin7 -action synchroauto from C:\divalto\sys with the same project and profile used by the preceding buildall compilation. - Report parsing: The parse_synchro.py script extracts the [TOTAL_ERRORS] marker and error lines with context, returning structured JSON and meaningful exit codes. - Schema delta extraction: The --changes mode summarizes the real DDL delta per table (added/dropped columns, created/dropped indexes, created/dropped tables, procedures, functions) while filtering backup-table and boilerplate noise. - Use Case: After a successful buildall with 0 errors on the 'divalto achat-vente.dhpt' project, run the synchronization, then parse Synchro.txt to confirm [TOTAL_ERRORS]0 or list the exact errors to fix. ## Quick Start Ask the assistant to synchronize the SQL database for your compiled Divalto project and parse the synchronization report to confirm zero errors.

Frequently Asked Questions about syncing-diva-sql

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I synchronize a SQL Server database after a Divalto buildall compilation?

Run xwin7 -action synchroauto with the same project and profile as the buildall, from the working directory C:\divalto\sys. The compilation must have finished with 0 errors, otherwise the compiled objects are inconsistent and the synchronization is invalid.

How do I parse a Divalto synchroauto report for errors?

Run parse_synchro.py --path on the report file. It extracts the [TOTAL_ERRORS] marker and error lines with context, returning JSON with success, total_errors, and errors fields. Exit code 0 means success, 1 means errors found, 2 means the report is unreadable.

Is there a dry-run mode for xwin7 synchroauto?

No, xwin7 synchroauto has no native dry-run option such as synchroscript or -noexec. A preview is possible programmatically via the ModeAudit mechanism, and the parse_synchro.py --changes mode provides an after-the-fact schema delta per table.

Why does xwin7 synchroauto fail with error code 3?

Error code 3 means the working directory was not C:\divalto\sys when xwin7 was called. Use Set-Location to switch to C:\divalto\sys before running synchroauto, and restore the original directory afterward.

What is the difference between the buildall and synchroauto report formats?

Buildall reports use the marker Erreur(s)=N, while synchroauto reports use [TOTAL_ERRORS]N. The two formats require different parsers, so do not reuse the buildall parsing logic on a synchronization report.

What does the parse_synchro.py --changes mode extract?

It extracts the real schema delta grouped by table: added and dropped columns, created and dropped indexes, created and dropped tables, plus procedures and functions. It filters noise such as *_oldcolumns backup tables, INSERT statements, sp_addextendedproperty, and regenerated ERASE_* procedures.