Click here to Skip to main content
15,902,636 members
Home / Discussions / Database
   

Database

 
GeneralRe: Dynamic CrystalReports Pin
Enobong Adahada30-Mar-10 22:01
Enobong Adahada30-Mar-10 22:01 
QuestionSQL IN statement or exists Pin
programmervb.netc++29-Mar-10 18:32
programmervb.netc++29-Mar-10 18:32 
AnswerRe: SQL IN statement or exists Pin
_Damian S_29-Mar-10 18:46
professional_Damian S_29-Mar-10 18:46 
AnswerRe: SQL IN statement or exists Pin
Mycroft Holmes29-Mar-10 19:11
professionalMycroft Holmes29-Mar-10 19:11 
AnswerRe: SQL IN statement or exists Pin
PIEBALDconsult31-Mar-10 8:38
mvePIEBALDconsult31-Mar-10 8:38 
GeneralRe: SQL IN statement or exists Pin
programmervb.netc++31-Mar-10 9:28
programmervb.netc++31-Mar-10 9:28 
QuestionReusable DataGridView and TableAdapter components in Lookup Tables? Pin
Bert Edens29-Mar-10 11:38
Bert Edens29-Mar-10 11:38 
AnswerRe: Reusable DataGridView and TableAdapter components in Lookup Tables? Pin
Mycroft Holmes29-Mar-10 19:05
professionalMycroft Holmes29-Mar-10 19:05 
This belongs in the design and architecture forum, certainly not the database forum, this has absolutely nothing to do with database.

Having said that, this is our standard design. First you need to chuck out the tableadaptor concept, you are using the MS widget/wizard crap things. Do some research into Data Access Layer, it will change the way you manage your data.

I have a utility that takes a datatable and binds it to a datagridview, formats the DGV and the various columns based on the data types of the datatable.

I have a giant switch statement that reacts to the node click event, gets the currentview (enum of all the tables to be displayed) from the node and decides what object to get a datatable from. The datatable is then passed to the DGV loader utility.

Then on the double click event of the DGV I already know what the currentview is from the loader so I know what form to display based on the currentview. I have the ID of the record clicked on (first filed always has the ID and is not visible in the DGV) so I pass the ID to the form in the constructor and pop a dialog.

The dialog gets the record (or an empty form for add) and saves the record back to the database. It returns a dialogresult to the main form.

If the main form get an Ok result it reloads the datatable from the database and refreshes the DGV with the new record in it.

As I said bog standard do it every day UI.
Never underestimate the power of human stupidity
RAH

GeneralRe: Reusable DataGridView and TableAdapter components in Lookup Tables? Pin
Bert Edens30-Mar-10 4:06
Bert Edens30-Mar-10 4:06 
QuestionGroup ranking or row number Pin
Lash2029-Mar-10 9:29
Lash2029-Mar-10 9:29 
AnswerRe: Group ranking or row number Pin
programmervb.netc++29-Mar-10 9:36
programmervb.netc++29-Mar-10 9:36 
AnswerRe: Group ranking or row number Pin
Mycroft Holmes29-Mar-10 18:48
professionalMycroft Holmes29-Mar-10 18:48 
QuestionHow do you handle Dev DB vs Production DB? Pin
programmervb.netc++29-Mar-10 9:22
programmervb.netc++29-Mar-10 9:22 
AnswerRe: How do you handle Dev DB vs Production DB? Pin
PIEBALDconsult29-Mar-10 18:09
mvePIEBALDconsult29-Mar-10 18:09 
GeneralRe: How do you handle Dev DB vs Production DB? Pin
programmervb.netc++29-Mar-10 18:35
programmervb.netc++29-Mar-10 18:35 
AnswerRe: How do you handle Dev DB vs Production DB? Pin
Mycroft Holmes29-Mar-10 18:54
professionalMycroft Holmes29-Mar-10 18:54 
QuestionDatabase design question Pin
Alivemau529-Mar-10 4:00
Alivemau529-Mar-10 4:00 
AnswerRe: Database design question Pin
J4amieC29-Mar-10 4:56
J4amieC29-Mar-10 4:56 
GeneralRe: Database design question Pin
Alivemau529-Mar-10 5:01
Alivemau529-Mar-10 5:01 
GeneralRe: Database design question Pin
J4amieC29-Mar-10 5:17
J4amieC29-Mar-10 5:17 
GeneralRe: Database design question Pin
Alivemau529-Mar-10 6:24
Alivemau529-Mar-10 6:24 
GeneralRe: Database design question Pin
programmervb.netc++29-Mar-10 9:11
programmervb.netc++29-Mar-10 9:11 
AnswerRe: Database design question Pin
riced29-Mar-10 5:57
riced29-Mar-10 5:57 
GeneralRe: Database design question Pin
Alivemau529-Mar-10 6:30
Alivemau529-Mar-10 6:30 
AnswerRe: Database design question Pin
Eddy Vluggen29-Mar-10 7:01
professionalEddy Vluggen29-Mar-10 7:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.