Search This Blog

Wednesday, March 19, 2014

AIF service, Importing, grouping data while importing.Problem and required solution

Requirement.

We have a Fixed positioned flat file from external system which have more than 1 million records where I have to import into LEDGERJOURNAL, customer doesn't want the all records as they want to group by the CURamt,DebtAmt based on the fields and date and load into the journal using  Standard AIF Service.

Environment: AX2012 R2 CU7.

I have one solution.
My Idea is.
1. Build the .net component that parse the flat file and do group by on that generate the XML using XSLT and use this component and xsl in transformations in AIFInbound port.

Do any one have any other Idea. Please provide the solution.

krishna.

5 comments:

  1. hi krishna i have one doubt how to integrate aif web service to mobile app in visual studio...

    Thanks,
    Arun joseph

    ReplyDelete
    Replies
    1. Hi Arun,
      you have to create AIF service and expose your service as WCF RestFulservice using WebHttpbinding.then you can use windowsAzureAPI using serviceBus.I think this was the new architecture for AX2015 Rainer for all Windows Apps.we have to wait until microsoft provided architecture.

      Delete
  2. Hi Krish, I tried giving you a suggestion to you on your requirement based on my understanding,

    Instead of creating the component, follow the below steps.
    1) Create a service reference in visual studio for the ledger journal service.
    2) just write some .net code (method) to read that file you have and group the records according to your fields
    3) Invoke the service for every grouped data from the method that that we used to group date from file.

    NS: The lederjournalservice with below link looks like this which need to be used per grouped data.
    http://blogs.msdn.com/b/axsupport/archive/2011/11/08/calling-the-ledgergeneraljournal-service-in-ax-2012.aspx

    Here you no need a .net component and also you don't need to use xslt transformations as well.

    Hope this help you.

    Thanks,
    Prasan

    ReplyDelete
    Replies
    1. Hi PrasannaKumar,
      Its not one time job, It should run every day, as every day we will get jobs from external system, so we have to load into AX daily in the night, so it should run in the batch. the above solution is for one time job, I dont have any userintervention to this job.

      Regards,
      krishna.

      Delete
  3. Hi,

    Why can't we run .net code on batch..? I have my code that run every 5 mins to invoke my webservices.. You can do that..

    Regard,
    Prasan

    ReplyDelete

Thanks for visiting my blog,
I will reply for your comment within 48 hours.

Thanks,
krishna.