Click here to Skip to main content
15,890,670 members
Home / Discussions / Database
   

Database

 
Questionquery optimization Pin
pstsp9117-Aug-10 13:07
pstsp9117-Aug-10 13:07 
AnswerRe: query optimization Pin
Mycroft Holmes8-Aug-10 2:04
professionalMycroft Holmes8-Aug-10 2:04 
AnswerRe: query optimization Pin
PIEBALDconsult9-Aug-10 17:21
mvePIEBALDconsult9-Aug-10 17:21 
Question0x00 byte problem while storing binary data to MySQL BLOB via ODBC (C API) Pin
whitesail7-Aug-10 2:24
whitesail7-Aug-10 2:24 
AnswerRe: 0x00 byte problem while storing binary data to MySQL BLOB via ODBC (C API) Pin
Blue_Boy7-Aug-10 5:07
Blue_Boy7-Aug-10 5:07 
GeneralRe: 0x00 byte problem while storing binary data to MySQL BLOB via ODBC (C API) Pin
whitesail7-Aug-10 11:00
whitesail7-Aug-10 11:00 
QuestionCommon Data validation best practice SQL & .Net? Pin
billyjoesunday6-Aug-10 4:54
billyjoesunday6-Aug-10 4:54 
AnswerRe: Common Data validation best practice SQL & .Net? Pin
Mycroft Holmes7-Aug-10 0:39
professionalMycroft Holmes7-Aug-10 0:39 
SQL Server already has all this meta data in the system views, these can be used for validation based on the existing tables.

Adding another layer of abstraction to manage all the data field lengths/formats sounds like a disaster looking for somewhere to happen. We use code generators so we can reproduce the relevant parts of the DAL/Model/ViewModel code, based on the database tables, this leaves us with the table and the UI/View to be refactored when a change is required.

A utility to validate the property based on the table would be trivial but you now need a property with a length attribute in your DAL/Model layer.

If you define a field standard lenght (eg name will always be 150 characters in length) there will always be exceptions.
Never underestimate the power of human stupidity
RAH

GeneralRe: Common Data validation best practice SQL & .Net? Pin
billyjoesunday12-Aug-10 5:00
billyjoesunday12-Aug-10 5:00 
GeneralRe: Common Data validation best practice SQL & .Net? Pin
Mycroft Holmes12-Aug-10 12:17
professionalMycroft Holmes12-Aug-10 12:17 
QuestionHow to insert values in to one table, data from two different tables? Pin
sarala.s6-Aug-10 2:15
sarala.s6-Aug-10 2:15 
AnswerRe: How to insert values in to one table, data from two different tables? Pin
thatraja6-Aug-10 2:27
professionalthatraja6-Aug-10 2:27 
AnswerRe: How to insert values in to one table, data from two different tables? Pin
Blue_Boy6-Aug-10 2:32
Blue_Boy6-Aug-10 2:32 
QuestionRe: How to insert values in to one table, data from two different tables? Pin
lovejun7-Aug-10 22:54
lovejun7-Aug-10 22:54 
AnswerRe: How to insert values in to one table, data from two different tables? Pin
Blue_Boy8-Aug-10 6:17
Blue_Boy8-Aug-10 6:17 
Questionsql function Pin
Thanusree Duth5-Aug-10 19:27
Thanusree Duth5-Aug-10 19:27 
AnswerRe: sql function Pin
Blue_Boy6-Aug-10 1:06
Blue_Boy6-Aug-10 1:06 
QuestionCalling Executables from CLR Procedure Pin
Shahzad.Aslam5-Aug-10 6:18
Shahzad.Aslam5-Aug-10 6:18 
QuestionGet Names from Id Pin
SatyaKeerthi155-Aug-10 0:25
SatyaKeerthi155-Aug-10 0:25 
AnswerRe: Get Names from Id PinPopular
Jörgen Andersson5-Aug-10 2:29
professionalJörgen Andersson5-Aug-10 2:29 
GeneralRe: Get Names from Id [modified] Pin
J4amieC8-Aug-10 23:41
J4amieC8-Aug-10 23:41 
GeneralRe: Get Names from Id Pin
David Skelly9-Aug-10 1:51
David Skelly9-Aug-10 1:51 
GeneralRe: Get Names from Id Pin
J4amieC9-Aug-10 1:53
J4amieC9-Aug-10 1:53 
GeneralRe: Get Names from Id Pin
Jörgen Andersson10-Aug-10 0:27
professionalJörgen Andersson10-Aug-10 0:27 
AnswerRe: Get Names from Id [modified] Pin
J4amieC8-Aug-10 23:43
J4amieC8-Aug-10 23:43 

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.