Question

Is it possible to create a VistaDB database programmatically using C#. My requirement is that I have a SQL Server database with some thousand rows and I want to programmatically create the same schema and export some hundred rows to an embedded database like VistaDB and ship to the client. I know I can use VistaDB data migration wizard, but I need to do it programmatically using C# ( because it is the client who will do the data export thing).

No correct solution

OTHER TIPS

Absolutely! Everything the data migration wizard and DataBuilder do ultimately is expressed as calls to the public API of the VistaDB engine. There are two ways to get things done - SQL Scripts (like you would use with SQL Server) and the DDA API which is proprietary to VistaDB. The current version of VistaDB has a number of differences between SQL Server's syntax and its accepted syntax for schema manipulation (that's a gap we're going to be closing with VistaDB 5) but you can do pretty much anything you want.

You may find it easiest to use the DDA API since it's more API oriented, less script oriented. Here is a good spot to get started in the documentation: VistaDB DDA Assembly Help

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top