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

Database

 
GeneralRe: Stored procedure / query optimization Pin
Steven Campbell28-Sep-04 8:19
Steven Campbell28-Sep-04 8:19 
GeneralRe: Stored procedure / query optimization Pin
Vagif Abilov28-Sep-04 8:52
professionalVagif Abilov28-Sep-04 8:52 
GeneralRe: Stored procedure / query optimization Pin
Steven Campbell28-Sep-04 9:48
Steven Campbell28-Sep-04 9:48 
GeneralRe: Stored procedure / query optimization Pin
Vagif Abilov28-Sep-04 9:55
professionalVagif Abilov28-Sep-04 9:55 
GeneralRe: Stored procedure / query optimization Pin
Colin Angus Mackay28-Sep-04 23:12
Colin Angus Mackay28-Sep-04 23:12 
GeneralRe: Stored procedure / query optimization Pin
Bill Dean29-Sep-04 6:31
Bill Dean29-Sep-04 6:31 
GeneralRe: Stored procedure / query optimization Pin
Steven Campbell29-Sep-04 8:30
Steven Campbell29-Sep-04 8:30 
GeneralRe: Stored procedure / query optimization Pin
Colin Angus Mackay29-Sep-04 13:24
Colin Angus Mackay29-Sep-04 13:24 
Steven Campbell wrote:
* do not use sa to login
* encrypt your database connection string
* use parameterized queries


The first and third of these I actually discussed in a blog entry of mine about a week ago so I am well aware of them.

Talking about Murphy's Law: Encrypting a connection string can be more trouble than it is worth. A project I saw recently had encrypted strings, but eventually comments started to appear next to them showing the string in decrypted form to make them easier to work with (it defeats the purpose really - Also, it is better to design a security system that people will not be inclined to break in order to do their everyday jobs). The other problem with encrypted connection strings is that you have to store a key to decrypt them somewhere. Better to use a trusted connection then it doesn't matter whether you know what my connection string is or not as you will still need to know the name and password of a trusted account and access it through a trusted domain.

Steven Campbell wrote:
I'll admit that stored procedures are a useful abstraction for programmers that do not break down their applications into multiple well defined areas of responsibility

Even if the application is broken into well defines areas I still think it is better to use stored procedures because they allow extra boundary checking. There are instances where a value on a record must be cross checked against other date to ensure validity. Constraints on tables can only go so far, for more complex checks SPs are better.

Again, security comes into play here as more security checks can be performed, even if they should have been performed elsewhere you cannot guarantee that another part of the application has not been compromised already.




Do you want to know more?

Not getting the response you want from a question asked in an online forum: How to Ask Questions the Smart Way!


GeneralRe: Stored procedure / query optimization Pin
Bill Dean30-Sep-04 2:21
Bill Dean30-Sep-04 2:21 
GeneralRe: Stored procedure / query optimization Pin
Jeremy Oldham29-Sep-04 13:50
Jeremy Oldham29-Sep-04 13:50 
GeneralRe: Stored procedure / query optimization Pin
Vagif Abilov29-Sep-04 19:40
professionalVagif Abilov29-Sep-04 19:40 
Generaleqivalent of "FOR UPDATE" Pin
WinDotNet27-Sep-04 19:35
WinDotNet27-Sep-04 19:35 
GeneralRe: eqivalent of "FOR UPDATE" Pin
Anonymous30-Sep-04 0:34
Anonymous30-Sep-04 0:34 
GeneralOracleClient StoredProcedure Pin
jzb27-Sep-04 17:01
jzb27-Sep-04 17:01 
QuestionAny way to optomize this? Pin
Jacob Hammack27-Sep-04 16:48
Jacob Hammack27-Sep-04 16:48 
AnswerRe: Any way to optomize this? Pin
Mike Ellison27-Sep-04 17:15
Mike Ellison27-Sep-04 17:15 
GeneralRe: Any way to optomize this? Pin
Jacob Hammack29-Sep-04 11:39
Jacob Hammack29-Sep-04 11:39 
AnswerRe: Any way to optomize this? Pin
Bill Dean29-Sep-04 6:50
Bill Dean29-Sep-04 6:50 
QuestionHow to position to row in DataTable or DataView Pin
magic4927-Sep-04 7:58
magic4927-Sep-04 7:58 
AnswerRe: How to position to row in DataTable or DataView Pin
Bill Dean29-Sep-04 7:01
Bill Dean29-Sep-04 7:01 
Generalsaving/retrieving image data in MSDE Pin
LongRange.Shooter27-Sep-04 7:40
LongRange.Shooter27-Sep-04 7:40 
GeneralPartial answer Pin
Steven Campbell27-Sep-04 8:30
Steven Campbell27-Sep-04 8:30 
GeneralRe: urgent can any help me ? Pin
Mike Ellison27-Sep-04 18:26
Mike Ellison27-Sep-04 18:26 
GeneralRe: urgent can any help me ? Pin
Colin Angus Mackay29-Sep-04 7:02
Colin Angus Mackay29-Sep-04 7:02 
GeneralRe: urgent can any help me ? Pin
Mike Ellison29-Sep-04 7:10
Mike Ellison29-Sep-04 7:10 

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.