Click here to Skip to main content
15,888,984 members
Home / Discussions / Database
   

Database

 
AnswerRe: connection parameters in configuration file Pin
Mycroft Holmes10-Jun-09 12:59
professionalMycroft Holmes10-Jun-09 12:59 
QuestionConfusion on Full Text Searching Pin
Brendan Vogt9-Jun-09 3:33
Brendan Vogt9-Jun-09 3:33 
AnswerRe: Confusion on Full Text Searching Pin
Eddy Vluggen9-Jun-09 7:23
professionalEddy Vluggen9-Jun-09 7:23 
QuestionPerfomance Question on the Following Query Pin
Vimalsoft(Pty) Ltd8-Jun-09 22:39
professionalVimalsoft(Pty) Ltd8-Jun-09 22:39 
AnswerRe: Perfomance Question on the Following Query Pin
J4amieC8-Jun-09 23:00
J4amieC8-Jun-09 23:00 
GeneralRe: Perfomance Question on the Following Query Pin
Vimalsoft(Pty) Ltd8-Jun-09 23:11
professionalVimalsoft(Pty) Ltd8-Jun-09 23:11 
AnswerCan you cache the data ? Pin
David Mujica9-Jun-09 2:48
David Mujica9-Jun-09 2:48 
GeneralRe: Can you cache the data ? Pin
Vimalsoft(Pty) Ltd9-Jun-09 20:57
professionalVimalsoft(Pty) Ltd9-Jun-09 20:57 
Good Morning Again

i have changed my statement and it look like this
/*This Function will get the Staff names based on the First Character 
* */
ALTER PROCEDURE [dbo].[sp_Staff_Select_NEW]
(
@lETTER VARCHAR(1)
)
AS
SELECT ID, DESCR, NOTE  
FROM TBL_STAFF
WHERE SUBSTRING(Descr,1,1)= @lETTER
GROUP BY Descr,NOTE,ID


This is what i changed.

1)I used a group by instead of a distinct

2)Above the i used char(2) while i was only accepting one character, its a small thing but one bit counts

3)i have added a index on the Field Descr

And it wo9rks like wonders the way it is fast.

Thank you for your Help and Comment

Vuyiswa Maseko

Vuyiswa Maseko,

Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."

C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/

GeneralCheck the Execution Plan Pin
David Mujica10-Jun-09 3:28
David Mujica10-Jun-09 3:28 
GeneralRe: Check the Execution Plan Pin
Vimalsoft(Pty) Ltd10-Jun-09 3:33
professionalVimalsoft(Pty) Ltd10-Jun-09 3:33 
QuestionDB2 Update Query Problem Pin
DBLearner8-Jun-09 6:38
DBLearner8-Jun-09 6:38 
AnswerRe: DB2 Update Query Problem Pin
Kschuler8-Jun-09 11:20
Kschuler8-Jun-09 11:20 
QuestionHome Business Service Solution (2295) Pin
furqanht rauf8-Jun-09 4:14
furqanht rauf8-Jun-09 4:14 
AnswerRe: Home Business Service Solution (2295) Pin
J4amieC8-Jun-09 4:27
J4amieC8-Jun-09 4:27 
QuestionTruncate Zeros Pin
mehrdadc488-Jun-09 3:26
mehrdadc488-Jun-09 3:26 
AnswerRe: Truncate Zeros Pin
J4amieC8-Jun-09 3:56
J4amieC8-Jun-09 3:56 
GeneralRe: Truncate Zeros Pin
smcnulty20008-Jun-09 13:34
smcnulty20008-Jun-09 13:34 
AnswerRe: Truncate Zeros Pin
Lau039-Jun-09 5:35
Lau039-Jun-09 5:35 
QuestionMS ACCESS Problem Pin
jonhbt8-Jun-09 3:08
jonhbt8-Jun-09 3:08 
AnswerRe: MS ACCESS Problem Pin
paas8-Jun-09 6:03
paas8-Jun-09 6:03 
Questionany recommendations on basic database books? Pin
cozandeffect8-Jun-09 0:03
cozandeffect8-Jun-09 0:03 
AnswerRe: any recommendations on basic database books? Pin
smcnulty20008-Jun-09 0:23
smcnulty20008-Jun-09 0:23 
AnswerRe: any recommendations on basic database books? Pin
Henry Minute8-Jun-09 1:58
Henry Minute8-Jun-09 1:58 
AnswerRe: any recommendations on basic database books? Pin
Jerry Hammond8-Jun-09 12:42
Jerry Hammond8-Jun-09 12:42 
QuestionProblem with fetching cursor into local variables Pin
mmdullah7-Jun-09 23:32
mmdullah7-Jun-09 23:32 

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.