Using a Script with variables

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
Posts: 390
Joined: Sat 09 Dec 2006 12:20

Using a Script with variables

Post by Zero-G. » Wed 01 Dec 2010 09:38


I am using dotConnect for mySQL (latest v5.8 Version) with VB.NET

I use the script component to make some changes to the database.
The script is an embedded file in my project.
Is it anyhow possible to use variables in the script?

For example. My script includes changes on a Trigger. - Therefor I have to use the "user" like Definer 'user'%'@'

Instead of user, there should stay the user, which is executing the script.

Hope you understand, what I mean. - Thanks for your tips
Yours faithfully

Devart Team
Posts: 7979
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Fri 03 Dec 2010 16:05

Please execute statements with parameters using the MySqlCommand class, because MySqlScript doesn't support parameters.

Post Reply