Toad World® Forums

Access Violation on module toad.exe but only from command line

Hi together,
sorry if I post this here but this is driving me mad.

I am running an automatic code review based on state of the art tools like Jenkins and sonar, and by using the sonar PL SQL plugin which in the end will call toad.
This all worked fine till yesterday, when I noticed the process was not running anymore.

After several hours, I found that everything is boiling down to jenkins calling a command like this:
toad.exe -CX F:\path\to\ini\cxfile.ini

The ini file is there and looks also fine. Tryed to connect with sqlplus and the credentials from the INI and it works fine. So connection should not be the problem.

Now if I run the above command manually, it is not working.
Toad will start and I can see in the taskbar

  • Connecting to Server 1 of 1
  • Preparing for Scan
  • Crash, error message appears: Access violation at adress 00FFF0AB in module toad.exe. read of address 00000008.

I have also enabled debugging with debug=1 in toad.ini. log is generated but no errors in there, the last lines contains something like:
-> TTeamCoding.executequery (‘select table_name, table_owner FROM ALL_SYNONYMS WHERE owner=‘PUBLIC’ and synonym_name =’!SYN_TC!’)

Application.Run

Nothing else.

So far I have tried the following with no luck:

  • Changing Toad options for startup
  • Removing .lay files from User files, as suggested on the net
  • Change to a new different Oracle client (tried with 10.2 and 10.2)
  • Change to a different Database
  • Tryed to change ini file in the command above, removing all the unecessary
  • tested with the same ini, on a complete different machine. Different os (Vista vs Server 2003), different client (11.2) and different database (11.2).

In all cases I am still seeing always the same error.
On the second machine I have MCafee AV, but on the first none (is a protected Server), so that cannot be the problem.

What is strage is that till some days ago it was working fine, and apparently there have been no changes on the server. Eventually some Patch updates?

Any Idea how to solve this??

thanks a lot and have a nice weekend
manuel

Can you search for a recent road.elf file and post it? Lots of people knows to
interpret those.

Groetjes, Wim de Lange

Op 2 mrt. 2012 13:39 schreef “deftones209” het
volgende:

Hi together,
sorry if I post this here but this is driving me mad.

I am running an automatic code review based on state of the art tools like
Jenkins and sonar, and by using the sonar PL SQL plugin which in the end
will call toad.
This all worked fine till yesterday, when I noticed the process was not
running anymore.

After several hours, I found that everything is boiling down to jenkins
calling a command like this:
toad.exe -CX F:\path\to\ini\cxfile.ini

The ini file is there and looks also fine. Tryed to connect with sqlplus and
the credentials from the INI and it works fine. So connection should not be
the problem.

Now if I run the above command manually, it is not working.
Toad will start and I can see in the taskbar
- Connecting to Server 1 of 1
- Preparing for Scan
- Crash, error message appears: Access violation at adress 00FFF0AB in
module toad.exe. read of address 00000008.

I have also enabled debugging with debug=1 in toad.ini. log is generated but
no errors in there, the last lines contains something like:
-> TTeamCoding.executequery ('select table_name, table_owner FROM
ALL_SYNONYMS WHERE owner='PUBLIC' and synonym_name
='!SYN_TC!')

Application.Run

Nothing else.

So far I have tried the following with no luck:
- Changing Toad options for startup
- Removing .lay files from User files, as suggested on the net
- Change to a new different Oracle client (tried with 10.2 and 10.2)
- Change to a different Database
- Tryed to change ini file in the command above, removing all the unecessary

- tested with the same ini, on a complete different machine. Different os
(Vista vs Server 2003), different client (11.2) and different database
(11.2).

In all cases I am still seeing always the same error.
On the second machine I have MCafee AV, but on the first none (is a
protected Server), so that cannot be the problem.

What is strage is that till some days ago it was working fine, and
apparently there have been no changes on the server. Eventually some Patch
updates?

Any Idea how to solve this??

thanks a lot and have a nice weekend
manuel

Manuel,
First, what version of Toad are you running? Next, can you run the same files/objects via the GUI in Toad? Also, is there any information in the CXCmdLineErrors.Log located in your user files folder?

Greg

Hi Greg,

I am running 9.7.2.5 Professional
Making CodExpert Analysis on the same files from GUI works. Also on other files did not have a Problem.
toad.elf does not shows anything relevant.
CXCmd…log is like this:

End run for C:\tmp\cx.ini at 02.03.2012 12:19:39
No Errors Found.

Here the Files I am using for testing(very simplified, but even this give the error).

I am starting toad like this:
toad.exe -CX C:\tmp\cx.ini

cx.ini
[OPTIONS]
RULESET=C:\tmp\rules.rst
RSET=min
OUTPUTDIR=C:\tmp
HTMLFILENAME=test.html
XMLFILENAME=test.xml
CODEXPERT_SCAN=1
SQL_SCAN=0
PASSWORDS_ENCRYPTED=0
INCLUDE_HTML=0
INCLUDE_XML=1
INCLUDE_SERVERSIDE_INSERT=0

[CONNECTIONS]
LOGIN1=someuser@somedatabase

[PASSWORDS]
PASSWORD1=somepassword

[FILES]
FILE1=C:\tmp\cx.sql

with the user/psw/db above I can connect from Toad and also from prompt with sqlplus.
cx.sql is like this (yes, i am doing the test as simple as possible)
select * from dual;

and rules.rst like this (also here stripped to the minimum)

I am running Oracle Client 11.2 on my Client, on Windows Vista.
Identical problem appears on Server with Oracle 10.1 and 10.2 Clients on Windows Server 2003 64.

Any help is very appreciated, i am starting to bang my head against the wall.
manuel

You mean toad.elf?
Yes, here below.
But when I run from command line (and only there it crashes) the toad.elf does not seems to be updated (mofified Date).
Indeed even if I have testing this today the whole days (03 march9 there seems to be no entries in there:
manuel

EurekaLog 6.0.15

Application:

Have you tried INCLUDE_HTML instead of INCLUDE_XML as a test? Toad uses MSXML to process the XML files so it’s possible that something got patched and is no longer compatible with the 9.7 code.

Greg

Hi Greg,

I have just tried with these settings (rest unchanged):

INCLUDE_HTML=1

INCLUDE_XML=0

Unfortunately still getting Access violation.

I have two Questions:

  • Is there a way to reproduce exactly on the Gui what it is doing with the
    command toad.exe -CX C:\tmp\cx.ini ?? I know how to run the export, but what is
    it doing apart from that 8some kind of XMl export)?

  • I have put also debug=1 in toad.ini, and I see a log coming out which always
    looks like this:

14:04:35 Initializing application

14:04:35 Creating GlobalDataModule

14:04:37 Performing Toad’s startup tasks

14:04:37 Setting Toad help file

14:04:37 Setting global options

14:04:37 Updating license key file with app info

14:04:37 Loading Formatter Plus

14:04:39 Creating main window

14:04:39 Create Bitmaps Form

14:04:40 Checking for Spotlight

14:04:40 Checking for SQL Impact

14:04:40 Initializing Team Coding

14:04:40 Building quick scripts menu

14:04:40 Building external tools menu

14:04:41 Restoring dock layout

14:04:41 Enabling features based on license

14:04:41 Restoring size and position

14:04:41 Performing Toad’s command line tasks

14:04:41 Calling OCI connect

14:04:41 Connected

14:04:41 Initializing connection

14:04:41 Getting Oracle version

14:04:41 Fetch session SID

14:04:41 Checking for access to DBMS_TRANSACTION

14:04:41 Checking for SELECT_CATALOG_ROLE

14:04:41 Setting module info

14:04:41 Creating Debugger Object

14:04:41 Checking for TOAD_PROFILER

14:04:42 get nls_charset from server

14:04:42 Restricting product features based on Toad security

14:04:42 Checking for RAC support…

14:04:42 Out of RAC support check.

14:04:42 Fetching owner names

14:04:43 TTeamCoding.AddTCSession

14:04:43 TTeamCoding.CheckSupport

14:04:43 -> TTeamCoding.ExecuteQuery( SELECT table_name, table_owner FROM
ALL_SYNONYMS WHERE owner = ‘PUBLIC’ AND synonym_name = ‘!SYN_TC!’ )

14:04:43

14:04:46 Application.Run

14:04:51 Checking connection’s active state

while if I start toad.exe and connect to a db it looks like

14:09:59 Initializing application

14:09:59 Creating GlobalDataModule

14:10:01 Performing Toad’s startup tasks

14:10:01 Setting Toad help file

14:10:01 Setting global options

14:10:01 Updating license key file with app info

14:10:01 Loading Formatter Plus

14:10:04 Creating main window

14:10:04 Create Bitmaps Form

14:10:05 Checking for Spotlight

14:10:05 Checking for SQL Impact

14:10:05 Initializing Team Coding

14:10:05 Building quick scripts menu

14:10:05 Building external tools menu

14:10:06 Restoring dock layout

14:10:06 Enabling features based on license

14:10:06 Restoring size and position

14:10:06 Performing Toad’s command line tasks

14:10:06 Application.Run

14:10:06 Create Login Form

14:10:12 Calling OCI connect

14:10:14 Connected

14:10:14 Initializing connection

14:10:14 Getting Oracle version

14:10:14 Fetch session SID

14:10:14 Checking for access to DBMS_TRANSACTION

14:10:14 Checking for SELECT_CATALOG_ROLE

14:10:14 Setting module info

14:10:14 Creating Debugger Object

14:10:14 Checking for TOAD_PROFILER

14:10:14 get nls_charset from server

14:10:14 Restricting product features based on Toad security

14:10:14 Checking for RAC support…

14:10:14 Out of RAC support check.

14:10:14 Fetching owner names

14:10:16 TTeamCoding.AddTCSession

14:10:16 TTeamCoding.CheckSupport

14:10:16 -> TTeamCoding.ExecuteQuery( SELECT table_name, table_owner FROM
ALL_SYNONYMS WHERE owner = ‘PUBLIC’ AND synonym_name = ‘!SYN_TC!’ )

14:10:16

14:10:17 TFormToadEditor.Create

14:10:17 Creating QSEEx (Loads QSE.dll)

14:10:17 Creating new editor tab

14:10:18 Loading desktop layout

14:10:19 Refreshing dbms_output data structure (not necessarily polling at this
time)

14:10:19 Desktop layout loaded

14:10:19 Parsing code

14:10:19 Code parsed

14:10:19 Clearing custom bookmarks

14:10:19 Custom bookmarks cleared

14:10:19 Clearing custom bookmarks

14:10:19 Custom bookmarks cleared

14:10:19 Refreshing the executable line map display

14:10:19 Line map refreshed

14:10:19 Loading saved breakpoints

14:10:19 Breakpoints loaded

14:10:19 Loading saved watches

14:10:19 Watches loaded

So it looks like having probmes here:

14:10:17 TFormToadEditor.Create

14:10:17 Creating QSEEx (Loads QSE.dll)

14:10:17 Creating new editor tab

14:10:18 Loading desktop layout

manuel

Is the CX.ini file being made by Toad or by the third party vendor? You can try
creating your own cx.ini file from the GUI and running that. Unfortunately,
there’s no way in that version of Toad to export the results as XML.

Greg

Hi Greg,

cx.ini has been generated by Sonar. I can generate my own for test, but in
production these files get generated automatically.

I have simplified it by removing the other 49 files being analysed, and just
keeping one.

But how do it create an INI from Toad?

Other Question.

If I put XML and HTML to 0, will it run anyway the analysis but not export
anything? So I could test if the problem lies in the export or in the analysis.

regards

manuel

Manuel,

On the main GUI, there’s a button with a button that looks like a command
prompt. You can use that to generate the ini file.

You also should be able to set them both to 0 and have it run – I think. That
version is pretty old and I’m not totally sure of what it did and didn’t do.

Greg

Hi,

there does not seems to be such an option in my Toad version.

I have tried with both XML and HTML to 0 and di not work. Even with CODEXpert to
0 did not work.

manuel

SEE ATTACHMENT

No maintenance – no support. No maintenance – they usually (depends on sales
person) on how you renew. Sometimes pay back supports fees + coming year.
Soemtimes cheaper to just rebuy. Number of copies does not mean free support.
image001.png

You should be able to right click in the GUI and get the Create Command Line
Parameter File item.
image001.png

You should be able to right click in the GUI and get the Create Command Line
Parameter File item.
image001.png

SEE ATTACHMENT
image001.png

SEE ATTACHMENT
image001.png

[OPTIONS]

RULESET=C:\Documents and Settings\gliss\Application Data\Quest Software\Toad for
Oracle\beta\RuleSets\All.rst

RSET=All Rules by Severity

OUTPUTDIR=C:\temp

HTMLFILENAME=CodeXpert.html

XMLFILENAME=CodeXpert.xml

CODEXPERT_SCAN=1

SQL_SCAN=0

PASSWORDS_ENCRYPTED=0

INCLUDE_HTML=1

INCLUDE_XML=1

INCLUDE_SERVERSIDE_INSERT=0

SEND_EMAIL=0

CLEAR_ERROR_LOG=1

SERVERSIDE_INSERT_RUNNAME=AUTOGENERATE

[FILES]

FILE1=

[CONNECTIONS]

LOGIN1=

[PASSWORDS]

PASSWORD1=

[OPTIONS]

RULESET=C:\Documents and Settings\gliss\Application Data\Quest Software\Toad for
Oracle\beta\RuleSets\All.rst

RSET=All Rules by Severity

OUTPUTDIR=C:\temp

HTMLFILENAME=CodeXpert.html

XMLFILENAME=CodeXpert.xml

CODEXPERT_SCAN=1

SQL_SCAN=0

PASSWORDS_ENCRYPTED=0

INCLUDE_HTML=1

INCLUDE_XML=1

INCLUDE_SERVERSIDE_INSERT=0

SEND_EMAIL=0

CLEAR_ERROR_LOG=1

SERVERSIDE_INSERT_RUNNAME=AUTOGENERATE

[FILES]

FILE1=

[CONNECTIONS]

LOGIN1=

[PASSWORDS]

PASSWORD1=
image001.png