Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Jul 05, 2012 05:52 AM by Chen Yu - MSFT
Jun 30, 2012 04:28 PM|LINK
I am trying to retrieve data from 2 tables in my database and show it on the formview.
After I drag in SQLdatasource control into the webform, and hit the radio button on specify a custom SQL statement or stored procedure, and later hit on the "Query builder" under the SELECT tab.
Following which, i added the tables in; aspnet_Membership and Details tables. After checking on the checkboxes of the column which I which to select and hit the "Execute Query" button.
here the problem, after running, the title of the column came out
but the rows of data inside the tables didn't appear.
if I join aspnet_Membership with another table, or Details table with another table, it work perfectly fine. Only when I join aspnet_Membership and Details table the data does not appear
what can i do? anyone help me please, i had been researching about this the whole day but was not fruitful.
Jul 03, 2012 08:04 PM|LINK
The most likely explanation is that the tables don't contain related data. On which columns are you joining? Are you sure that the Details table contains records that have a column that matches the column you're joining on from the Membership table?
Jul 05, 2012 05:52 AM|LINK
Just like @Imar said, if two tables didn't have match column, it will not show any data in output. Please make sure that the condition you use is the matched column in two tables. You could select each table to check it. If they didn't have matched column,
it seems you need to use another condition in your query. If you use JOIN in your query, you could reference on below link to choose one.