[Manifold-l] query.text vs. query.run()

vincent lacour vlacour at worldonline.fr
Wed Jul 26 01:50:35 CDT 2006


I am trying to create a table with vb.net using the query class.

My script reads:

Imports Manint = Manifold.Interop
Imports manscript = Manifold.Interop.Scripts

Sub main()
    Dim monapp As Manint.Application
    Dim mondoc As Manint.Document
    Dim monsql As Manint.Query

    monapp = New Manint.Application
    mondoc = monapp.NewDocument("g:\thermiques\test.map", False)
    monsql = mondoc.NewQuery("creation tables")
    monsql.Text = "CREATE TABLE [Pilotes] ([IDpilote] INTEGER DEFAULT 0,
[Pilote] TEXT DEFAULT """");"
    monsql.Run()
    ' ......
exit sub

When I run the script step by step in debug mode, the new table is created
at monsql.text line and monsql.run brings an error because the [Pilotes]
table cannot be created twice.  If I comment out the monsql.run() line, it
works fine.
When I run the script full speed, I need the monsql.run() instruction.

Do I need some sort of refreshing of the mondoc.componentset?
Seems to me that some communication is missing between the SQL part and
vb.net

I would appreciate any help/explanation.

Cheers

Vincent




More information about the Manifold-l mailing list