Following is not classic example of QBE, but it will be helpful for our coding with MySql back end.rathinagiri wrote:Can you explain with a small example?BTW, does anyone have any idea how to create an app which will create SQL code by QBE (Query By Example)?
A. This will be helpful mainly when we refresh array from MySql (or any other sql database) table.
For a table with large number of fields, we have to type all (or selected) fields, which leads to typo error
So, if we have a utility where
1) we can select a database, table
2) when we select a table, all fields will be stored in different rows of a grid with check box for each row.
3) we can select all or selected fields by clicking check box
Then SQL code will be generated as per our selection. In that case, I prefer code will be within quotes with 60 character line limit, so that we can directly copy and paste into our HMG code.
B. For Report. Here we need joining more than one table with selection of fields, ORDER BY fields, GROUP BY fields etc.
A good example may be MS Access -> Query builder.
Here also generated code will be stored within quotes with 60 character line limit.
Please note that those are very basic ideas only
With best regards.
Sudip