Toad does not return the same records someone else returns

Had a problem while working on a cutover project. I did not have any rollbacks or commits pending durring my session. I did have 3 connections open at the same time : 2 in the same databasse (different schema) and one open in another database. I was running a query to determine how many records had a particular condition. Upon returning the results we realized the returned records was smaller than it should have been. I was missing records, so I reran the query. Thinking the query was not constructed correctly I gave the query to a colleague and he ran it as it was sent. He retrieved more records than I (he had my missing records). This was concerning since our go-live status was based upon the success of this query. I had to shutdown toad by closing all connections. After the shutdown I was able to retrieve the correct number of records. This happened more than once and on different days. I am not able to reconstruct it because in the prior case we knew what to look for. Now I don’t have the conditions set exactly.

Any ideas???

Jerry

A possible solution, but possibly a long shot too!

Are you running your queries in a separate thread/ connection in Toad?

If so, did the session checking the counts, start executing before the session that did the commits?

Reading your email I do note that you recreated the problem on subsequent occasions, so the above is most likely not your cause. :frowning:

Of course, someone else might have been “playing” with your data and committed after your query but before your colleague’s query. But on separate days?

It’s quite a mystery! Sorry I don’t have much useful input.

Cheers,

Norm [ TeamT ]

Sent from my Android device with K-9 Mail. Please excuse my brevity.

ONe other thought…how are you executing the query - F5 (as a script) or F9? F5 has the ability to run scripts in a new session or the existing Toad session. F9 has the ability to run in threaded mode.

George, hi! I usually run one query at a time in the sql window. I use the icons so am not sure if I am running the F5 or F9 (run as a script when more than one statement is terminated with an ; ). I am pretty sure it happened again this am. How can I capture this to be more helpful in identifying what is happening?

Jerry

From: Gregory Liss [mailto:bounce-GTDG@toadworld.com]

Sent: Tuesday, November 24, 2015 7:09 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Toad does not return the same records someone else returns

RE: Toad does not return the same records someone else returns

Reply by Gregory Liss

ONe other thought…how are you executing the query - F5 (as a script) or F9? F5 has the ability to run scripts in a new session or the existing Toad session. F9 has the ability to run in threaded mode.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.

All things are equal between you and your colleague when testing, e.g., connected as same schema, etc.?

On 11/24/2015 08:43 AM, gerald.gionet wrote:

RE: Toad does not return the same records someone else returns

Reply by gerald.gionet
George, hi! I usually run one query at a time in the sql window. I use the icons so am not sure if I am running the F5 or F9 (run as a script when more than one statement is terminated with an ; ). I am pretty sure it happened again this am. How can I capture this to be more helpful in identifying what is happening?

Jerry

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.

Yes that is how I found the problem. My colleague did the same query with different results. Got the items I was missing.

Very strange. Am wondering if I can turn something on to see why my query brings back different results.

Jerry

From: Michael Staszewski [mailto:bounce-mstaszew@toadworld.com]

Sent: Tuesday, November 24, 2015 9:45 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Toad does not return the same records someone else returns

RE: Toad does not return the same records someone else returns

Reply by Michael Staszewski

All things are equal between you and your colleague when testing, e.g., connected as same schema, etc.?

On 11/24/2015 08:43 AM, gerald.gionet wrote:

RE: Toad does not return the same records someone else returns

Reply by gerald.gionet

George, hi! I usually run one query at a time in the sql window. I use the icons so am not sure if I am running the F5 or F9 (run as a script when more than one statement is terminated with an ; ). I am pretty sure it happened again this am. How can I capture this to be more helpful in identifying what is happening?

Jerry

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.

I would also try running the query via SQLPlus on your machine to see if it returns the correct results. F5 (execute as a script) and SQLPlus should return the identical information.

From: gerald.gionet [mailto:bounce-geraldgionet@toadworld.com]

Sent: Tuesday, November 24, 2015 11:16 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Toad does not return the same records someone else returns

RE: Toad does not return the same records someone else returns

Reply by gerald.gionet

Yes that is how I found the problem. My colleague did the same query with different results. Got the items I was missing.

Very strange. Am wondering if I can turn something on to see why my query brings back different results.

Jerry

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.

Okay will do. Thank you.

From: Gregory Liss [mailto:bounce-GTDG@toadworld.com]

Sent: Tuesday, November 24, 2015 11:52 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Toad does not return the same records someone else returns

RE: Toad does not return the same records someone else returns

Reply by Gregory Liss

I would also try running the query via SQLPlus on your machine to see if it returns the correct results. F5 (execute as a script) and SQLPlus should return the identical information.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle - General
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.