.Net connecter Query Help
Posted by:
Keld Deck
Date: August 21, 2006 09:34PM
Alright I got 1 Server Multiple Tables and they all have fields all with 'ID'
So I got something like this
Field Names
|----- Table 1 = ID, Mom, Dad, Brother, Sister
Server |----- Table 2 = ID, Cat, Dog, Hamster, Rabbit
|----- Table 3 = ID, Joe, Greg, Bob, Tommy
Now I got a single App that will read a MYSQL server data and display the results but now Im comming across a problem, how can I use a single query such as
Code:
myAdapter = New MySqlDataAdapter("SELECT * FROM Clients", conn) 'ORDER BY ID ASC // Can Be Asc or Desc
myAdapter.Fill(Mydata)
DataGridView1.DataSource = Mydata
/Code:
to display the fields and all the results, But I want to for what ever Table they select to get all the Information from all the fields Execpt the ID field so In the end it should Display all the Fields and all the Data but the ID field in a datagrid, Anyideas?
Thanks
Basicly to sum up the end result it should show if I picked Table1
Mom, Dad, Brother, Sister and the Data Under them Table1
Cat, Dog, Hamster, Rabbit and the Data Under them Table2
Joe, Greg, Bob, Tommy and the Data Under them Table3
Is fetching the Field names into an Arrow and excluding ID the only way, Anyone can give me some sample code so I can figure out this problem?