WDSC tips/DEBUG

From MidrangeWiki
Jump to: navigation, search

This is an interactive alternative to the IBM i command STRDBG.

Debug and SEP Service Entry Points

original post [1] (the post contains a lot of other information)

  • In Iseries Table View
  • Right Click on the Source
  • Select Debug(service Entry)/Set Service Entry Point
  • Next Panel Click OK (I have not done Service Programs)
  • If you get a 'Iseries Debug Message has not been started yet' message, follow the instruction, then try again.
  • When the SEP is is set click OK.
  • Run the program, however you normally would, eg. call, menu option, whatever.
  • You need to run the program under the User Profile in the SEP
  • If you change the Profile in the SEP your profile needs to have *USE rights to the profile running the job and your profile should have *SERVICE special authorities.
Check Service Entry Point, if you need to change the user profile of the SEP.
  • The WDSC Debug view should pop up and you can set breakpoints view variables etc. etc. check Interactive Debugger


#top


UPDPROD (*YES)

original post [[2]]

  • Window -> Preferences -> Run/Debug -> iSeries Debug
  • the first check box on the dialog is "Update production files"

#top

Clear Breakpoints

original post [3]

  • In the Debug perspective
  • Click the Breakpoints tab
  • There is an icon, (looks like a double X) to remove all Breakpoints

You can manage ALL of your breakpoints across multiple programs and multiple languages, both on the client and on the server. You can enable and disable them, as well as remove them entirely.

#top

Field Values

original post [[4]]

  • Window -> Preferences -> Run/Debug -> Compiled Debug
  • Check Tick, 'Always use Debugger Editor while debugging'

FWIW I also Check Tick

  • Allow hover evaluation
  • Double-Click in Debugger Editor to add monitored expression
  • Centre view on execution line

(FKOL 21:17, 4 February 2008 (CST))

In V6.0, the debugger started to use iSeries Editor as the default editor to display the source. The fly over expression evaluation was available in OPM RPG, ILE RPG and ILE COBOL.

Thanks to Don Yantzi, to have hover evaluation work for CL programs, switch to the listing view or use the debug editor instead of the RSE Lpex editor.

#top

Debug Breakpoints not breaking

original post [[5]]

When Debugging, also when debugging SQLRPGLE

  • Use listing view
  • Turn off all caching. Window -> Preferences -> Remote systems -> File Cache, ______ Click 'Clear cached files'
  • Window -> Preferences -> Remote systems -> iSeries -> Cache, ______ Check 'disable caching' and click on the 'Clear cache' button.
  • Refresh the table view often, especially before setting the SEP.

#top

Debug a crashed Job

original post [[6]]


  • In the Remote Systems view
  • Find the job under iSeries Jobs
  • Right-click the job and select Debug As.

The easiest way is to right-click on an active job and you can select debug from the menu.

An alternative is to choose Run > Debug Configurations...> IBMi: Debug Job and create a new configuration. You'll need the fully qualified job name. More details at the RDi_job_debugger page.

#top

Debug server not starting

original post [[7]]


Check QUSRWRK subsystem is active. STRDBGSVR submitted job goes to the queue QUSRNOMAX. Started the subsystem and all is well.

#top

Displaying the Contents of a Table

original post [[8]]

In the Monitor View, click on the Plus icon to bring up Monitor Expression dialog.

Type "TABPRV(1..9)" in the entry field.


#top