join multiple tables as datasource for datagrid - DataForm.NET Samples

This example illustrates how to use join statement to display fields from multiple tables.

Pick a Theme:

Order Details 
 Order ID AscendingProduct IDProduct NameUnit PriceQuantityDiscount  
1024951Manjimup Dried Apples42.4000400.00 %
1025041Jack's New England Clam Chowder7.7000100.00 %
1025051Manjimup Dried Apples42.40003515.00 %
1 - 3 / 2143 RecordsPage / 715 

  Design   Source  
  1. Open DataForm.NET Manager. In DataForm.NET List page, choose Order Details by clicking the link.
  2. In the DataForm.NET Designer on the right hand side, switch to GridForm tab.
  3. ProductName field is from Products tables. Such field can be added by the form at the bottom of table. There are five attributes needed to specified(Column Name, Field TitleColumn Type and Order). After you click "Add Field" button, this field will show up in the table above.
  4. Click "ProductName" link to open up GridForm Fields Designer window.
  5. Switch to "Database" tab. The Datasource Name may be already specified. And by default, the Display Column is the same as the Column Name. But you can change it if you want to display different column.
  6. The SQL join statement can be written inside the big textbox. Or you can pick corresponding tables and fields and click "Get Join Statement" link to help you generate the join statement. Make sure Join statement is corrent, then save and preview GridForm.
  • Click HERE to open up a READ ONLY DataForm.NET Manager.
  • Click HERE to try for yourself.