sql_editor_save_file
Save SQL editor content as .sql files locally or to SAS Viya, checking overwrite and version conflicts before replacing existing files.
Instructions
Save the editor's SQL as a .sql file in the SQL Editor's folder, or to a file on SAS Viya.
An existing file is only replaced with ``overwrite``; otherwise the result
says ``exists`` so the app can ask first.
SAS Viya files (``name`` a ``sas-content://`` / ``sas-server://`` ref): ``expected_version`` is the version
(ETag) the editor opened; when the file on Viya is newer the result says ``conflict`` (nothing written) and
the app asks before saving with ``overwrite``. A ref of another SAS Viya connection than the active one
answers ``connection_mismatch``; ``use_active`` saves it to the same path on the active connection.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | ||
| name | Yes | ||
| overwrite | No | ||
| use_active | No | ||
| expected_version | No |