Code Analysis not working from Command Line

Hi All,

I am trying to run code analysis from the command line using parameter file to generate output in XML format but file is not getting generated. After checking the log file I am getting error that failure:nothing to do.

If I try same parameter file in automation designer window of toad, XML file is getting generated.

Can anybody help me why I am getting error using command line?

Thanks

Nitin Goyal

Hi Nitin, my apologies, could you please re-post your question into the Toad Oracle forum ( www.toadworld.com/…/10.aspx ). The developers that monitor that forum will be able to get you an answer.

Thanks,

Daniel–

No need to re-post. I’ve moved the thread for you.

-Steve

Can you post the contents of the ini file you’re using? Also, are you using the -cx or the -a with a parameter file? Can you run it via the GUI?

Greg

Hi All,

I am using -a with a parameter file. If I use -c that time It says nothing to execute but if I don’t give connection string it just without giving any error.

I am able to execute the parameter file from GUI.

Please find below the parameter file used

[49]

Name=Code_Analysis1

Type=Code Analysis

ConnectionCount=1

Connection_1=test@test.WORLD

[OPTIONS]

RULESET=D:\Sev_Warn.rst

RSET=Sev_Warn

OUTPUTDIR=D:\test\

HTMLFILENAME=.html

XMLFILENAME=CodeAnalysis1.xml

METRICHISTORYFILENAME=.xls

XLSFILENAME=.xls

CODEXPERT_SCAN=1

SQL_SCAN=0

PASSWORDS_ENCRYPTED=0

INCLUDE_HTML=0

INCLUDE_XML=1

INCLUDE_XLS=0

INCLUDE_SERVERSIDE_INSERT=0

INCLUDE_METRICS_HISTORY=0

SEND_EMAIL=0

CLEAR_ERROR_LOG=1

SERVERSIDE_INSERT_RUNNAME=AUTOGENERATE

[CONNECTIONS]

LOGIN1=test@test.WORLD

[PASSWORDS]

PASSWORD1=test

[FILES]

FILE1=D:\test_package1.sql

FILE2=D:\test_package2.sql

Thanks

Nitin Goyal

The proper syntax for running Code Analysis with a parameter file is this:

toad.exe -a " | "

In addition, if you don't have "save passwords" checked, you need to add the connection command line call.

Greg

On Jul 4, 2014, at 2:36 AM, "nitingoyal88" bounce-nitingoyal88@toadworld.com wrote:

RE: Code Analysis not working from Command Line

Reply by nitingoyal88
Hi All,

I am using -s with a parameter file. If I use -c that time It says nothing to execute but if I don't give connection string it just without giving any error.

I am able to execute the parameter file from GUI.

Please find below the parameter file used

[49]

Name=Code_Analysis1

Type=Code Analysis

ConnectionCount=1

Connection_1=test@test.WORLD

[OPTIONS]

RULESET=D:\Sev_Warn.rst

RSET=Sev_Warn

OUTPUTDIR=D:\test\

HTMLFILENAME=.html

XMLFILENAME=CodeAnalysis1.xml

METRICHISTORYFILENAME=.xls

XLSFILENAME=.xls

CODEXPERT_SCAN=1

SQL_SCAN=0

PASSWORDS_ENCRYPTED=0

INCLUDE_HTML=0

INCLUDE_XML=1

INCLUDE_XLS=0

INCLUDE_SERVERSIDE_INSERT=0

INCLUDE_METRICS_HISTORY=0

SEND_EMAIL=0

CLEAR_ERROR_LOG=1

SERVERSIDE_INSERT_RUNNAME=AUTOGENERATE

[CONNECTIONS]

LOGIN1=test@test.WORLD

[PASSWORDS]

PASSWORD1=test

[FILES]

FILE1=D:\test_package1.sql

FILE2=D:\test_package2.sql

Thanks

Nitin Goyal

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.

Hi Greg,

I have tried both the below commands:

toad.exe -c username/password@sid -a apps->code| d:\parameter1.ini

and

toad.exe -a apps->code| d:\parameter1.ini

I am able to execute the second command if my password is saved in connection file but if I try to run with connection string I will get error nothing to do.

Thanks

Nitin Goyal

Just a dumb thought - and may not work, but have you tried placing connection data inside double quotes:

toad.exe -c “username/password@sid” -a apps->code| d:\parameter1.ini

The reason I suggest this is that sometimes complex parameters need passed in Windows enclosed inside double quotes to be safe - for example when a directory includes a space in its name - and maybe the special chars / and @ are causing issues …

Worth a quick try :slight_smile:

Also placing the apps in quotes as well

toad.exe -c “username/password@sid” -a “apps->code| d:\parameter1.ini”

From: Bert Scalzo [mailto:bounce-Bert_Scalzo@toadworld.com]

Sent: Tuesday, July 08, 2014 6:57 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Code Analysis not working from Command Line

RE: Code Analysis not working from Command Line

Reply by Bert Scalzo

Just a dumb thought - and may not work, but have you tried placing connection data inside double quotes:

toad.exe -c “username/password@sid” -a apps->code| d:\parameter1.ini

The reason I suggest this is that sometimes complex parameters need passed in Windows enclosed inside double quotes to be safe - for example when a directory includes a space in its name - and
maybe the special chars / and @ are causing issues …

Worth a quick try :slight_smile:

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.

Hi All,

Thanks for the help, But no luck. :frowning:

I have tried toad.exe -c “username/password@sid” -a “apps->code| d:\parameter1.ini” command but getting same issue… Nothing to execute.

Thanks for trying - was hoping it might work but was not optimistic it would. But clearly now you’ve done everythign possible - so must be a toad thing.

I suggest opening a ticket with support at this point. Running CA from the command line using a parameter file has been tested as part of 12.6 internal regression
testing, so there must be something more to this issue. Support will be able to collect more information from you off-line to help troubleshoot this issue.

From: Bert Scalzo [mailto:bounce-Bert_Scalzo@toadworld.com]

Sent: Tuesday, July 08, 2014 10:24 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Code Analysis not working from Command Line

RE: Code Analysis not working from Command Line

Reply by Bert Scalzo

Thanks for trying - was hoping it might work but was not optimistic it would. But clearly now you’ve done everythign possible - so must be a toad thing.

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 take this back. Greg just filled me in on your case. If you want to still go through support you can, but it’s not necessary at this point.

From: Brad Boddicker [mailto:bounce-ButtonPusher@toadworld.com]

Sent: Monday, July 14, 2014 9:47 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Code Analysis not working from Command Line

RE: Code Analysis not working from Command Line

Reply by Brad Boddicker

I suggest opening a ticket with support at this point. Running CA from the command line using a parameter file has been tested as part of 12.6 internal regression
testing, so there must be something more to this issue. Support will be able to collect more information from you off-line to help troubleshoot this issue.

From: Bert Scalzo [mailto:bounce-Bert_Scalzo@toadworld.com]

Sent: Tuesday, July 08, 2014 10:24 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Code Analysis not working from Command Line

RE: Code Analysis not working from Command Line

Reply by Bert Scalzo

Thanks for trying - was hoping it might work but was not optimistic it would. But clearly now you’ve done everythign possible - so must be a toad thing.

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.