HomeActive Query BuilderAdding a table programmatically

Adding a table programmatically


Hello,
I'm using the .NET version.

Is it possible to add a table to the tables catalog programmatically?
Some of my tables are the result of a pivot query, so the actual columns are dynamic and not predefined.

Is this the right approach or do you have other suggestions?

Thanks.
Gai Tamir | email
December 3 2007, 04:18 AM
I saw the example from another post:

MetadataObject tableOrders = qb.MetadataContainer.AddTable("MySchema", "Orders", false, "MyDB");
tableOrders.Fields.AddField("OrderID");
tableOrders.Fields.AddField("OrderDate");
tableOrders.Fields.AddField("CustomerID");
tableOrders.Fields.AddField("ResellerID");

but, I can't find the MetadataContainer property anywhere.
Gai Tamir | email
22 mins since original post
Dear Gai,

The MetadataContainer property is available in the Trial and Standard versions and is not available in the Free version. The trial request form is available at the download page.

By the way, have you found the Non-visual sample project that you've asked before?

Sincerely
Sergey Smagin
Sergey Smagin | email
12 hours, 25 mins since original post
Yes, I found the sample (I was looking for it in the free edition) after I've downloaded the trial version.

Thanks for your response,
Gai Tamir.
Gai Tamir | email
21 hours, 58 mins since original post
This topic is closed