Click here to Skip to main content
15,920,031 members
Home / Discussions / Database
   

Database

 
QuestionCLOB Convert to String Pin
ytubis16-Apr-07 4:57
ytubis16-Apr-07 4:57 
AnswerRe: CLOB Convert to String Pin
Krish - KP16-Apr-07 21:36
Krish - KP16-Apr-07 21:36 
QuestionHow do I protect Access database (MDB file)? Pin
testmail_12316-Apr-07 2:44
testmail_12316-Apr-07 2:44 
AnswerRe: How do I protect Access database (MDB file)? Pin
Dave Kreskowiak16-Apr-07 4:18
mveDave Kreskowiak16-Apr-07 4:18 
GeneralRe: How do I protect Access database (MDB file)? Pin
testmail_12317-Apr-07 1:06
testmail_12317-Apr-07 1:06 
AnswerRe: How do I protect Access database (MDB file)? Pin
Mark J. Miller16-Apr-07 12:26
Mark J. Miller16-Apr-07 12:26 
QuestionHelp with cursor Pin
allende16-Apr-07 1:54
allende16-Apr-07 1:54 
AnswerRe: Help with cursor Pin
Pete O'Hanlon16-Apr-07 2:02
mvePete O'Hanlon16-Apr-07 2:02 
Most of the time, when I see somebody say they need a cursor I can't help thinking that they've missed out on the alternatives. This seems to be the case here. You probably don't need to use a cursor. What you could do is to create a temporary (or in memory) table that contains details of all of the unfilled orders. Then, once you have done this, you would write your update statements for the other tables based on this table.

What you will find is that this approach is more efficient because it allows the database engine to operate in a set based manner which is what DB engines are designed to do.

As an example (in pseudocode)
SELECT the missing records
FROM orderDetails
INTO a Temporary Table.

UPDATE order WITH THE itemTotals FROM Temporary Table
WHERE THE Item Id IN Temporary Table
MATCHES THE Id in my Item TABLE.

Do the other tables here...
Anyway, that's what I would do.



Deja View - the feeling that you've seen this post before.

GeneralRe: Help with cursor Pin
allende16-Apr-07 2:53
allende16-Apr-07 2:53 
GeneralRe: Help with cursor Pin
Pete O'Hanlon16-Apr-07 5:12
mvePete O'Hanlon16-Apr-07 5:12 
GeneralRe: Help with cursor Pin
allende16-Apr-07 5:43
allende16-Apr-07 5:43 
GeneralRe: Help with cursor Pin
Pete O'Hanlon16-Apr-07 22:50
mvePete O'Hanlon16-Apr-07 22:50 
Questionsql query Pin
Shuaib wasif khan16-Apr-07 1:25
Shuaib wasif khan16-Apr-07 1:25 
AnswerRe: sql query Pin
Christian Graus16-Apr-07 1:43
protectorChristian Graus16-Apr-07 1:43 
QuestionJoin table Pin
AnhTin15-Apr-07 20:33
AnhTin15-Apr-07 20:33 
AnswerRe: Join table Pin
Colin Angus Mackay15-Apr-07 21:08
Colin Angus Mackay15-Apr-07 21:08 
QuestionSQL Cursor Pin
playout15-Apr-07 20:09
playout15-Apr-07 20:09 
AnswerRe: SQL Cursor Pin
Christian Graus15-Apr-07 20:32
protectorChristian Graus15-Apr-07 20:32 
QuestionHelp Me Pin
Mkanchha15-Apr-07 20:00
Mkanchha15-Apr-07 20:00 
AnswerRe: Help Me Pin
_mubashir15-Apr-07 20:10
_mubashir15-Apr-07 20:10 
GeneralRe: Help Me Pin
Mkanchha15-Apr-07 20:25
Mkanchha15-Apr-07 20:25 
QuestionHelp Me soon Pin
Mkanchha15-Apr-07 19:41
Mkanchha15-Apr-07 19:41 
AnswerRe: Help Me soon Pin
_mubashir15-Apr-07 19:59
_mubashir15-Apr-07 19:59 
GeneralRe: Help Me soon Pin
Mkanchha15-Apr-07 20:02
Mkanchha15-Apr-07 20:02 
Questionwhat is the differenece these two statements Pin
shabonaa15-Apr-07 10:58
shabonaa15-Apr-07 10:58 

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.