• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 295
  • Last Modified:

Dataset Query


I'm using vb.net and the dataset designer to get data from a mysql database.

In the dataset designer, I've added a query to the datatable, I'd like to know if I can programmatically change the sql query that's stored in this datatable at run time.

Currently to get the data I'm using :

            cliTableAdapter2 = New simplyDataSetTableAdapters.DataTable2TableAdapter
            cliDataSet2 = New simplyDataSet
            Return cliDataSet2

        Catch ex As Exception
            Throw ex
        End Try

Open in new window

I've tried using a wildcard in the SQL statement to use a parameter at run time but it gives me the following error : No mapping exists from dbType Object to a known OdbcType.

I'd like to know If I can change that sql string at runtime to something else.

Thank you
  • 2
1 Solution
Bob LearnedCommented:
I don't understand what you are looking for, and what that exception means...

How would you like to change the SQL string?
FCapoAuthor Commented:
Thank you but I found an alternative to doing this, sorry for wasted time
FCapoAuthor Commented:
The question wasn't well formulated and I found a solution through different means!

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now