SQLExport from MDriven Server
No edit summary
No edit summary
 
Line 1: Line 1:
{{Edited|July|12|2025}}
<message>Write the content here to display this box</message>
<message>Write the content here to display this box</message>
==== SQLExport ServerSide Action ====
==== SQLExport ServerSide Action ====
Line 16: Line 15:


'''<span style="color: #1a50ad">The MDriven Book</span>''' - '''Next Chapter:''' [[Documentation:OCL Expressions|OCL Expressions]]
'''<span style="color: #1a50ad">The MDriven Book</span>''' - '''Next Chapter:''' [[Documentation:OCL Expressions|OCL Expressions]]
{{Edited|July|12|2025}}


[[Category:Advanced]]
[[Category:Advanced]]
[[Category:MDriven Server]]
[[Category:MDriven Server]]
[[Category:The MDriven Book]]
[[Category:The MDriven Book]]

Latest revision as of 05:55, 18 March 2025

This page was created by Hans.karlsen@mdriven.net on 2019-02-28. Last edited by Stephanie@mdriven.net on 2025-03-18.

SQLExport ServerSide Action

The SQLExport action is used to write data from your model into another external SQL database. It is an alternative way to export data that needs no other external components or maintenance than what MDriven Server provides.

SQLExport requires 'connectionstring' on root, 'data' (column name must start with 'data', case insensitive) as a Nesting that contains the data row(s) to insert or update, and on data - 'queryforinsert','queryforupdate' and 'queryforselectcount' as attributes (if queryforselectcount returns 0 the queryforinsert is used, else update).

Update 2018-10-18: You can now use 'connectionstringodbc' and the logic will use ODBC connection instead.

The very common case of “replicating” some model-driven data to another database is implemented and scheduled in minutes.

Exporting files from MDriven Server 06.png

Common Gotchas

The data nesting must be collected even when you work in 1 object -> do self->asset

The MDriven Book - Next Chapter: OCL Expressions