Forum Discussion

MarshallArts's avatar
MarshallArts
Experienced Partner
11 days ago

JobRegister queries

I have a custom reporting application which has been running for years.  It can report activity by GL Account or by Job.  The client using it makes extensive use of Jobs, with a small number of top-level Jobs representing their operational departments.  Most have many sub-jobs.  Every transaction in their system is assigned to a Job.  The application obtains activity by Job using a query to the JobRegister endpoint, with a filter specifying the JobNumber of the top-level Job.  Up until recently this has worked fine, even if the top-level job is a header job (as most of them are).  But it has now stopped working.  I have had to change the app to extract all the sub-jobs of each top-level Job, make separate queries to the JobRegister endpoint for each of them, then add it all up myself.  I think this has slowed the application down a bit.

 

Has anyone else encountered this?  It seems to me that something has definitely changed in the MYOB universe.  Was this a deliberate change by MYOB, or has something gone wrong?  Should I be able to get all activity for a hierarchy of Jobs by querying at the top-level Job, or is it a fluke that it has worked all this time?  I can deal with what is happening, but it would be nice to know if the original way I was doing it should still be working.  This is a .NET application and uses the MYOB SDK package.  I did update that package recently, to the latest available version.  But there have been no changes to the way the application extracts data for at least a year, probably more.  Until now, to address this problem.

  • The_Doc's avatar
    The_Doc
    Ultimate Partner

    Hi MarshallArts 

     

    I cannot directly answer this as I don't use the SDK to access their endpoints - for the reason that you are at their mercy to how the code works for accessing endpoints.

     

    I have a client using jobs, sub jobs etc - and I can have a look at a page extracted from the endpoint as post it to you - it should then give you perhaps a bit more info about your query.

     

    The other thing you can do - simply code up a simple form in VB.NET with the jobsregister endpoint to see the json payload you get back - it should help you further.

     

    Re my client - I may not extract the data to the depth you do from the jobs register but my client hasn't had any problem - and jobs are extremely important in my package.

     

    The Doc

  • MarshallArts's avatar
    MarshallArts
    Experienced Partner

    Thanks for the reply.  So does your package call the JobRegister endpoint filtering on a header job, and get back the activity on all its sub-jobs?  That's the specific bit that appears to have changed, for me anyway.

    • The_Doc's avatar
      The_Doc
      Ultimate Partner

      Hi MarshallArts 

      I work differently to you with Endpoints - why - because I don't use the MYOB SDK where all the data is extracted via Abstract Methods - you get to see whatever MYOB decides.

       

      I write my own extractions - so I use Endpoints to get me a page of JSON data - then I decide whether the info I need is in that endpoint - payroll is a good example - there is no payroll endpoint that will give you all payroll data - but mix and match different endpoint including GeneralLedger and it all comes together.

       

      Here is an extract of a JobRegister endpoint  - but you would need a copy of theJobRegister from before the suspected change. Then you could compare them.

      You need to do a bit of Sherlock Holmesing to work out what has changed then work backwards into the SDK to see where it has changed.

       

      Sorry, I can't be more helpful - but the way I extract data from endpoints is coding more intensive but I remain fully in control of the data I need.

      The Doc