Re: Getting the SQL while running from eclipse

From: Anjo Krank (kran..ogicunited.com)
Date: Tue Nov 09 2004 - 05:31:36 EST

  • Next message: Guido Neitzer: "Class not found"

    Am 09.11.2004 um 11:19 schrieb Anders Peterson:

    > Are you using WONDER? It seems to override arguments sent to an
    > application by eclipse (as specified in the launch configuration).
    >
    > I haven't learned much about WONDER yet. I've simply started to
    > inherit from various ERX* classes.
    >
    > As you can see from the console output (below) I do get "SQL", but
    > after ERXProperties has done it's thing, it's gone.

    You might want to specify
    -Dlog4j.loggerFactory=er.extensions.ERXLogger$Factory (you need to
    escape the $ like "\\\$" when running from the command line)

    And you could put the EOAdaptorDebugEnabled into a file
    ~/WebObjects.properties and "touch" it. Then on the next reload you
    should see your logs again.

    log4j.category.er.transaction.adaptor.EOAdaptorDebugEnabled=DEBUG
    log4j.category.er.transaction.adaptor.EOAdaptorDebugEnabled.BackTrace=IN
    FO

    another way to log SQL is:

    log4j.category.er.extensions.ERXAdaptorChannelDelegate.sqlLogging=DEBUG
    er.extensions.ERXAdaptorChannelDelegate.maxMilliSeconds=<some time>
    er.extensions.ERXAdaptorChannelDelegate.enabled=true

    Which will log only long-running statements.

    Cheers, Anjo



    This archive was generated by hypermail 2.0.0 : Tue Nov 09 2004 - 05:31:45 EST