Click here to Skip to main content
15,903,030 members
Home / Discussions / Database
   

Database

 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? [modified] Pin
JTRizos21-Dec-10 6:04
JTRizos21-Dec-10 6:04 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
Mycroft Holmes21-Dec-10 11:17
professionalMycroft Holmes21-Dec-10 11:17 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
JTRizos21-Dec-10 11:40
JTRizos21-Dec-10 11:40 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
Mycroft Holmes21-Dec-10 13:19
professionalMycroft Holmes21-Dec-10 13:19 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
JTRizos22-Dec-10 6:26
JTRizos22-Dec-10 6:26 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
Mycroft Holmes22-Dec-10 11:13
professionalMycroft Holmes22-Dec-10 11:13 
GeneralRe: MSSQL - How can I reference a column to update using a variable?? Pin
JTRizos22-Dec-10 11:48
JTRizos22-Dec-10 11:48 
QuestionExplain Explain for me! Pin
Chris Meech20-Dec-10 7:04
Chris Meech20-Dec-10 7:04 
Looking for some expertise with explains. I've a database procedure that is refusing to behave properly since it has been migrated from Oracle 9i to Oracle 10g. It runs completely in under 3 minutes on my Oracle 9i database, but on 10g it will take either 32 minutes or 10 minutes to complete depending upon whether the statistics are estimated or the table is analyzed. I've been using the DBMS_PROFILER and have narrowed it down to a for loop involving a cursor. However when I explain the cursor, I not only have two different plans, 9i vs 10g, but the costs are completely different, except that 10g is the much reduced costs!
Oracle 9i EXPLAIN
Operation                      Options         Object                    Optimizer
------------------------------ --------------- ------------------------- -------------
  SELECT STATEMENT Cost = 1405                                           CHOOSE
    FILTER
      TABLE ACCESS             FULL            TRANSACTION_TABLE         ANALYZED
      FILTER
        NESTED LOOPS           OUTER
          MERGE JOIN           CARTESIAN
            FILTER
              NESTED LOOPS     OUTER
                INDEX          UNIQUE SCAN     XPKTRANSACTION            ANALYZED
                INDEX          RANGE SCAN      XPKTRANSACTIONLOT         ANALYZED
            BUFFER             SORT
              INDEX            RANGE SCAN      XPKTRANSACTION            ANALYZED
          INDEX                RANGE SCAN      XPKTRANSACTIONLOT         ANALYZED

Oracle 10g EXPLAIN
Operation                      Options         Object                    Optimize
------------------------------ --------------- ------------------------- ---------
  SELECT STATEMENT Cost = 374                                            ALL_ROWS
    FILTER
      TABLE ACCESS             BY INDEX ROWID  TRANSACTION_TABLE         ANALYZED
        INDEX                  RANGE SCAN      IXTRANSACTION_FIFO        ANALYZED
      FILTER
        HASH JOIN              RIGHT OUTER
          INDEX                RANGE SCAN      XPKTRANSACTIONLOT         ANALYZED
          NESTED LOOPS
            FILTER
              NESTED LOOPS     OUTER
                INDEX          UNIQUE SCAN     XPKTRANSACTION            ANALYZED
                INDEX          RANGE SCAN      XPKTRANSACTIONLOT         ANALYZED
            INDEX              RANGE SCAN      XPKTRANSACTION            ANALYZED


Anybody with some good explain foo that could suggest some things to try in order to speed this puppy up. Thanks. Smile | :)
Chris Meech
I am Canadian. [heard in a local bar]

In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]

posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

AnswerRe: Explain Explain for me! Pin
Jörgen Andersson20-Dec-10 10:07
professionalJörgen Andersson20-Dec-10 10:07 
RantRe: Explain Explain for me! Pin
Mycroft Holmes20-Dec-10 16:14
professionalMycroft Holmes20-Dec-10 16:14 
GeneralRe: Explain Explain for me! Pin
Jörgen Andersson20-Dec-10 23:51
professionalJörgen Andersson20-Dec-10 23:51 
GeneralRe: Explain Explain for me! Pin
Chris Meech21-Dec-10 2:11
Chris Meech21-Dec-10 2:11 
GeneralRe: Explain Explain for me! Pin
Chris Meech21-Dec-10 2:16
Chris Meech21-Dec-10 2:16 
QuestionHow to Display transactions happened in sqlserver 2005 Pin
nainakarri19-Dec-10 21:58
nainakarri19-Dec-10 21:58 
AnswerRe: How to Display transactions happened in sqlserver 2005 Pin
Hiren solanki19-Dec-10 22:49
Hiren solanki19-Dec-10 22:49 
GeneralRe: How to Display transactions happened in sqlserver 2005 Pin
nainakarri20-Dec-10 0:00
nainakarri20-Dec-10 0:00 
QuestionError Can't serliase access for the transaction Pin
kjsl2k919-Dec-10 18:08
kjsl2k919-Dec-10 18:08 
AnswerRe: Error Can't serliase access for the transaction Pin
Jörgen Andersson20-Dec-10 10:29
professionalJörgen Andersson20-Dec-10 10:29 
QuestionSQL Server Memmory problem Pin
MAW3019-Dec-10 11:35
MAW3019-Dec-10 11:35 
AnswerRe: SQL Server Memmory problem Pin
Mycroft Holmes19-Dec-10 11:57
professionalMycroft Holmes19-Dec-10 11:57 
QuestionConnect C# Application to network Oracle 10g install Pin
PDTUM18-Dec-10 8:10
PDTUM18-Dec-10 8:10 
AnswerRe: Connect C# Application to network Oracle 10g install Pin
Mycroft Holmes18-Dec-10 12:21
professionalMycroft Holmes18-Dec-10 12:21 
GeneralRe: Connect C# Application to network Oracle 10g install Pin
PDTUM18-Dec-10 13:57
PDTUM18-Dec-10 13:57 
AnswerRe: Connect C# Application to network Oracle 10g install Pin
Jörgen Andersson18-Dec-10 13:07
professionalJörgen Andersson18-Dec-10 13:07 
GeneralRe: Connect C# Application to network Oracle 10g install Pin
PDTUM18-Dec-10 13:55
PDTUM18-Dec-10 13:55 

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.