CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviReport (Moderator: Dave Greenberg) »
  • InstanceId, Location of the paramater
Pages: [1]

Author Topic: InstanceId, Location of the paramater  (Read 851 times)

donniemooretn

  • I’m new here
  • *
  • Posts: 29
  • Karma: 0
    • TN Hands & Voices
  • CiviCRM version: 4.4.3
  • CMS version: WordPress 3.8
  • MySQL version: 5.5.27
  • PHP version: 5.4
InstanceId, Location of the paramater
November 04, 2012, 08:45:20 pm
I am a little confused as to the location of the parameter for the instanceId.   I have a cron job that is setup to run the 'mail_report'.  When setting up the Schedule Job... (see image)  am I supposed to include the parameter in the Command Box?  For example one of the reports that I want to send on a weekly basis (which is already setup in the Cron Job on my server) is instanceId=18.

my cron job is scheduled to run every Friday. the Cron job link is   mysite.com/wp-content/plugins/civicrm/civicrm/bin/cron.php?job=mail_report&name=username&pass=password&key=2f2f67e754d5fa2db0784402b3f81a4e (The username and Password is really there, just not listed here)

The error message in the log is:
2012-11-04 22:35:24   Mail Reports   
0
Summary
Finished execution of Mail Reports with result: Failure, Error message: Report Mail Triggered... Required parameter missing: instanceId
Details


Parameters raw (from db settings):
instanceId=18

Parameters raw (From cron.php):
a:2:{s:20:"civicrm_install_type";s:9:"wordpress";s:7:"version";i:3;}

Parameters parsed (and passed to API method):
a:2:{s:20:"civicrm_install_type";s:9:"wordpress";s:7:"version";i:3;}

Full message:
Finished execution of Mail Reports with result: Failure, Error message: Report Mail Triggered...
Required parameter missing: instanceId

  • schedule job image is attached.

Thanks!

Donnie Moore

Deepak Srivastava

  • Ask me questions
  • ****
  • Posts: 677
  • Karma: 65
Re: InstanceId, Location of the paramater
November 05, 2012, 11:46:55 pm
Looked at the code, i think its by design that when you run cron from url, all parameters are expected from url - http://wiki.civicrm.org/confluence/display/CRMDOC42/Managing+Scheduled+Jobs#ManagingScheduledJobs-RunaSpecificJobviaURL

So its expecting for "&instanceId=18" in the url.

Did you try running from Job scheduler UI itself ? Should work from there, incase you just want to test it.
« Last Edit: November 06, 2012, 12:25:11 am by Deepak Srivastava »
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviReport (Moderator: Dave Greenberg) »
  • InstanceId, Location of the paramater

This forum was archived on 2017-11-26.