Quantcast
Channel: Microsoft Dynamics 365 Community
Viewing all 17314 articles
Browse latest View live

D365 for Operations – Creating a mobile workspace

$
0
0
In case you missed it there was a new mobile app framework released in update 4 that allows you to take data from D365 screens and present them in a mobile app. First you will need to download the app...(read more)

AX 2012: Attach documents or creates notes through X++

$
0
0
Recently came across a requirement to attach documents and create notes for a sales order after reading files from directories.

Documents can be attached to a sales order manually from the following button.







Code snippet to create notes or attach documents

 DocuRef             docuRef;
 DocuActionArchive   docuArchive;
 SalesTable          salesTable = SalesTable::find("SO00001");

 Filename            fileName = @"C\Temp\SalesOrder.docx";

 ttsbegin;

 // Code to create notes
 docuRef.TypeId = 'Note';
 docuRef.Name = "Sales order notes";
 docuRef.Notes = "Checked Postcode: 2000, Select resident type";
 docuRef.Restriction = DocuRestriction::External;
 docuRef.RefTableId = tableNum(SalesTable);
 docuRef.RefRecId = salesTable.RecId;
 docuRef.RefCompanyId = curext();
 docuRef.insert();

 //Code to attach file
 docuArchive = newDocuActionArchive();
 docuArchive.add(docuRef, fileName);

 ttscommit;


DocuRef Table has field RefTable and RefRecId which could be referenced by any table in AX and with any record respectively.

Do set RefCompanyId field in DocuRef table otherwise records will not create.


Production Order – Consuming un-planned materials

$
0
0
When you setup AX for production you usually create a bill of materials to indicated material you plan to use in a typical production process. When you create a production order then you can use the BOM...(read more)

What if your organization still prefers a network file share? Consider the updated Azure File Services.

$
0
0
Many of the companies I've worked with have embraced cloud solutions due to their desire to "get out of the datacenter business." The ability to achieve better security and availability, and the speed with which they are able to deploy ...read more

Language issue in AX 2012 with Views built on security tables

$
0
0
Some of the security related system/kernel tables in AX 2012, like for example SecurityRole, is backed by Views in the model store.

If you look at the Views in the model store you can see that some fields hold a label id rather than a text. For SecurityRole, the fields Name and Description holds label ids.

Somewhere in the AX kernel these label ids are converted to actual texts according to the language of the user. So inside AX we don't see these labels, but we see the language specific texts.

This is also the case if you create a View where these tables are part of the meta data.

However if you change the language for your user, it doesn't seem like these Views are updated according to the new language. They keep returning data in the previous language, even after restarting the client and AOS. The only way I have found to make it use the new language is to manually synchronize the view from the AOT.

New Dynamics 365 Enterprise training material on the DLP

$
0
0
Microsoft’s Dynamics Learning Portal (DLP) is regularly being updated with a lot of new Dynamics 365 Enterprise training material. To help you keep track of the evolution of the course catalogue...(read more)

What does Hard Seal mean for you?

$
0
0
Hard seal of App Suite announced on Dynamics 365 Tech Conference made a lot of noise in AX community, so I wrote a blog post for my company’s blog to explain impact for our customers http://www.intergen...(read more)

Dynamics 365 CSP; What happens when a customer is not paying their monthly bill?

$
0
0

Disclaimer: In this blog post I would like to share my understanding on what is happening when customers no longer pay their bill for Dynamics 365. Please consult with your partner or Microsoft to get the actual and official interpretation.

First some definitions; Most mid-size customers will buy Dynamics 365 through a partner that is a CSP (Cloud Solution Provider). Larger corporations will have the opportunity to buy Dynamics 365 directly from Microsoft through a EA (Enterprise Agreement). The information here is related to the CSP way of purchasing licenses.

When buying Dynamics 365, most customers will receive a monthly bill from their CSP partner. But the great thing about the CSP, is that you may adjust the number of users for the next period. Dynamics 365 have a low limitation of 20 licenses, but above this the customer may make changes.

But keep in mind that even though you receive a bill for the upcoming month, there is still a commitment for the base subscription period. For Dynamics 365, the subscription period is normally 12 months. I think I finally understood why the name is Dynamics 365; The reason may be that you have to buy it for at least 365 days

As stated earlier the customer normally receives a bill each month. But what happens when the customer stops paying the bills?

1. Well first the normal procedure is that the customer is notified by their CSP that payments are missing that follows the normal procedure.

2. The next step is that the CSP partner will suspend the subscription. This is done when by changing the status on the subscription to “Suspended”.

3. When a subscription status is changed to “Suspended”, this puts the subscription into a “data retention” mode. This means that end-users will not have access to any services, but administrators will still have access to the data associated with this subscription.

4. At the end of 60 days after a subscription is Suspended, the subscription is moved to a “de-provisioned” state. At this time, all data is removed.

The conclusion is therefore; Pay you bill or lose your data.

When I think of it…… it’s just like paying your electric bill.. no pay…no power.

 

 



Use Microsoft Flow to start up your Azure VMs

$
0
0
Having Azure VM's running when no one uses them is the cloud equivalent of setting your money on fire. 

With the ARM deployments we can do for D365fO now, we can pretty easy make the machines shut down automatically based on a schedule:


But how about startup? If you start a machine manually it takes a while before you can connect to it and use it. So it is preferred to start machines before the workday starts. 

If you control startup with scheduled RunBook scripts you risk starting machines that will not be used during the day. Developers might be on other projects, being sick or being on vacation.

So I have been looking into using Microsoft Flow to start machines. The idea is that a developer opens his/her Flow app before leaving their home in the morning to start the machines they want to work on that day. Here is how that could look in the Flow app:

    
To get there, first step is to create an Azure Automation account and create the RunBook for starting a VM. You can find the RunBook as a template in the Azure Portal. The process is very well described in this article on the Axology blog: https://axology.wordpress.com/2016/12/09/automated-startup-and-shutdown-of-azure-vms/

The Flow app is very simple to setup. Here are the steps for creating the app button (sorry, some of this is in danish).

First add the manual trigger:


Then add the action, which in this case is an "Azure Automation - Create job" action:



Finally I get a notification when the job is done. Not when the machine actually runs, but when the job kicking off the startup is done:


That is it for a really simple flow. You can probably think of a lot of bells and whistles to add.

I would like to try it out with one of the physical buttons that works with Flow, like Flic, as the trigger:



Microsoft Dynamics Partner Roundup: Payment processing for GP; NAV Master ISV; Customer engagement go-live; IT service management

$
0
0
In this week's Microsoft Dynamics Partner News Roundup: ConnectBooster Announces New Accounting Integration into Microsoft Dynamics GP The Agiles Group Announces NAV-X as Master ISV for North American Market Visionet Systems ...read more

SharePoint server and SharePoint online improvements for 2017

$
0
0
In May 2016, Microsoft officially launched SharePoint 2016, the latest iteration of its enterprise collaboration platform.(read more)

4 more Power BI content packs for 2017

$
0
0
Warehouse and operations managers will be able to monitor the key inbound, outbound and inventory metrics; and analyse warehouse performance in the past, present, and future.(read more)

Parallel inventory valuation – an alternative approach (Part 4)

$
0
0
After the purchase and internal standard cost variances have been analyzed, let’s now have a look at the production related standard cost variances and how to deal with them. Within this fourth part...(read more)

April release – Dynamics AX 2012 R3

$
0
0

The April release for Dynamics AX 2012 R3 version is now available in LCS on the updates tile inside your R3 project. This update represents a typical collection of smaller functional improvements and technical fixes.  Bugs were fixed in all areas with enhancements found in Warehouse & Transportation, Production and Project Accounting. Please see the full list of hotfixes below to search for your specific issue newly included in this release. This release is a cumulative package including all other fixes released in the prior CU12 update.  Several have commented in prior monthly releases for R3, if there is a slipstream install of this package, and there is not.  This release is intended to give visibility into fixes recently shipped for R3, including some features and design changes that are newly released in this month.

Here are a few details related to this release: 

  • Primary Build: 6.3.5000.3703 
  • Number of Application hotfixes: 96 
  • Number of Binary hotfixes: 12 

 Details of the install process can be found here: https://technet.microsoft.com/en-us/library/hh538446.aspx#PackageR3 

What is included in this month’s release? 

Design Change Requests, Feature Requests & RegFs 

KB Details Description of issue or change request  Description of enhancement 
4014132 Unable to report consumption of staged and order picked material. Enhancement has been made to unable reporting of actual consumption that allows to register material that is either reserved physcial or picked. 
4014541 Item trace crashes when there are many work transactions Changes made by creating a custom class instead of InventTrans to cache item tracing data 
4014110 Finland:  Generic ISO20022 CredTrans FI format should include payment id Fixed the issue described 
4014542 Tax branch information is mandatory on PND53 report but it is missing on AX 2012 R2.  Added Tax Branch Information in related reports. 
4015070 Traceability of the voucher information is inconsistent Code changes are made to get Invoice Register and Approval details not the Invoice Journals as that is what is on VendTrans. 
4013179 Questionnaires linked to a vendor request are lost after approval Added new button to show the original vendor request. 

 

 

Fixes Released 

 

KB Number Complete Feature Path Title 
4014057 DAXSE\AX Retail The inventtablemodule records related to Purchasing are sent to stores, and you may need to reduce volume of data synchronized to channel database.
4014330 DAXSE\AX Retail\Solution WCF related parameters in Pos.exe.config file seems corrupted. 
4014155 DAXSE\AX Retail\Solution\BI and Reporting Call center sales orders capture card payments when a pro forma invoice is printed 
4014151 DAXSE\AX Retail\Solution\BI and Reporting\HQ reports Cannot use measure  “ retail  transaction Lines  “ to  showing  net  amount  per site dimension in Retail Cube 
4013748 DAXSE\AX Retail\Solution\Channel management Unit price cannot be updated successfully for intercompany sales order line due to the regression of DAXSE #3794316. 
4012727 DAXSE\AX Retail\Solution\Financials\Statement Posting Validation for Missing Barcode items should not include Price-embedded or Weight-embedded barcode items. 
4014056 DAXSE\AX Retail\Solution\Financials\Statement Posting IC gift card post voided lines in IC transaction 
4014742 DAXSE\AX Retail\Solution\Store operations and POS Inventory lookup search text box is placing the hyphens character up front of the entered characters 
4014866 DAXSE\AX Retail\Solution\Store operations and POS EPOS: Auto logoff timeout’ value ignored when accessing standard reports and ‘Manage Shifts’ screen. 
4014452 DAXSE\AX Retail\Solution\Store operations and POS\UX – MPOS MPOS price check : Cannot use barcode if it is identical with item number 
4015372 DAXSE\AX Retail\Solution\Store operations and POS\UX – MPOS Sorting undefined in Modern POS for Categories from Hierarchy [Continue DAXSE#3810513 – KB#4013353] 
4014137 DAXSE\AXL Stock card Financial shows wrong quantity – Thai Localization 
4014138 DAXSE\AXL Button Continuity schedule in Sales order form always enabled for Polish localization 
4014144 DAXSE\AXL\APAC localizations [China] Disposal of fixed asset wrong in ledger 
4014136 DAXSE\AXL\APAC localizations\India Batch number is not getting updated in RG Excise Registers 
4015545 DAXSE\AXL\APAC localizations\Japan JP – Some typos on Form 26  
4014139 DAXSE\AXL\APAC localizations\Singapore Malaysia and Thailand TH-Withholding tax is incorrect with multiline invoice journals 
4013704 DAXSE\AXL\Europe Localizations HUN – Selected values in field Sales tax receivable exchange rate type and field Sales tax payable exchange rate type displays value ‘Unretrieved 
4014540 DAXSE\AXL\Europe Localizations\Belgium Belgium Sales tax report and Purchase transaction report shows wrong value in box 87 when tax code is setup with “Pct. Exempt from sales tax” – follow up from 3809202 
4014535 DAXSE\AXL\Europe Localizations\Eastern Europe\Hungary Belgian Sales tax transactions re sales report does not report boxes 3 & 49 
4014134 DAXSE\AXL\Europe Localizations\Eastern Europe\Poland PL – Adv Holder with Full Access available only for System Admin 
4014140 DAXSE\AXL\Europe Localizations\Eastern Europe\Poland Incorrect update in InventTrans for Polish Credit Note 
4014143 DAXSE\AXL\Europe Localizations\Eastern Europe\Poland PL – Adv Holder with wrong Dim for Emp belongs to multiple entity 
4014147 DAXSE\AXL\Europe Localizations\Eastern Europe\Poland Poland: Incorrect VAT amount displayed on General journal 
4013625 DAXSE\AXL\Europe Localizations\France FEC EcritureLet and DateLet methods not created for R2 / hotfix to be backported 
4014146 DAXSE\AXL\Europe Localizations\France Bill of exchange document reference on remittance is not updated correctly 
4015543 DAXSE\AXL\Europe Localizations\Germany German sales tax report does not print base amount of individual tax codes on line 41 
4014135 DAXSE\AXL\Europe Localizations\Italy [Italy] AX2012 R3 Italian sales tax payment report returns wrong Sales tax for the previous periods 
4014163 DAXSE\AXL\Europe Localizations\Norway Norway: ISO20022 CT – if voucher series for vendor payments has – sign, importing Camt.054 file fails – unknown EndToEnd id 
4015138 DAXSE\AXL\Europe Localizations\Russian Federation\AP AR (RUS) Exchange rate adjustments are missing dimensions 
4010939 DAXSE\AXL\LATAM Localizations\Brazil NF-e: <orig> tag is always 0 for a Sales Order NF-e (generated from a project) with a “Create inventory movements = no” 
4013522 DAXSE\AXL\LATAM Localizations\Brazil NF-e: “528 – Rejection: ICMS amount differs from the Item, Base amount and Tax percentage” error for a Direct Import NF-e with foreign currency due to incorrect rounding 
4015009 DAXSE\AXL\LATAM Localizations\Brazil NF-e: Rejection code 699 (Nota Tecnica 2015/003 version 1.92) 
4014145 DAXSE\AXL\LATAM Localizations\Mexico MEXICO – CFDI does not print PDF if RFC has ñ 
4014261 DAXSE\AXL\LATAM Localizations\Mexico When configuring AX for the ‘Electronic ledger accounting statement’ report, the ‘Tax registration’ tab (in Basic > Setup > Company information) only becomes available IF the ‘CFDI (electronic invoices)’ feature is enabled 
4014084 DAXSE\Client\Controls\Shared Controls Controls on the Item Coverage form remain editable, even with View only permissions 
4015185 DAXSE\Client\Office Add-ins Excel shown error when open saved excel file with IFERROR function 
4014342 DAXSE\Developer and Partner Tools\DIXF DIXF Opening Balances entity will not import Account\Offset Account values if a Dimension is used in an Account Structure via an Advanced Rule 
4014897 DAXSE\Enterprise Portal\Enterprise Portal\Navigation AX 2012 R3- Enter key does not work for lookup in Enterprise Portal  
4015028 DAXSE\GFM\Accounts Receivable Excel Add-In for Free-Text Invoice will not populate an Address from a Customer Account 
4014465 DAXSE\GFM\Case Management Cannot register and follow up on cases. 
4013935 DAXSE\GFM\Cash Management\Bank\Bank Reconciliation AX2012 R3 CU12 – Advanced bank rec – Opening and closing balances should not be required with BAI2 format 
4015029 DAXSE\GFM\Cash Management\Bank\Reports Dates appear to be incorrect on the bank reconciliation report while generate report from Cash and Bank Management > Journals > Bank Reconciliation>Print Reconciliation Statement 
4015541 DAXSE\GFM\Cash Management\Vendor\Payments and Settlement Payment proposal should use findByMainAccountLegalEntity to retrieve main account 
4012159 DAXSE\GFM\Fixed Assets Depreciation catch up (Depreciation adjustment) not generated in case of asset disposed in mid of month 
4014863 DAXSE\GFM\General Ledger You entered a reason that already exists in the reason table when trying to enter a description on the journal voucher form for an allocation journal 
4015520 DAXSE\GFM\General Ledger Cannot update the period status for a Fiscal calendar period. 
4015540 DAXSE\GFM\General Ledger Error Cannot edit a record in Ledger journal table when closing the journal line form after selecting another company journal  
4013189 DAXSE\Human Resources\Payroll Oregon Transit Tax is not calculating since the 2016-R9a tax update – R3 
4013769 DAXSE\Human Resources\Payroll No support for FSA Dependent Care Limits 
4013826 DAXSE\Human Resources\Payroll The Deduction amount is incorrect when you have a time zone set in Organization Administration Address Setup 
4015361 DAXSE\Human Resources\Payroll NACHA file does not generate block count appropriately for 61 employees 
4014388 DAXSE\Public Sector\AR Custom text entered on Free Text Invoice line does not get retained while correcting the Free Text Invoice 
4013747 DAXSE\Public Sector\Budget\Provisional budgeting France: Commitment accounting – partly used commitment shows unexpected balances after revising the commitment 
4012810 DAXSE\Public Sector\GL\Periodic Purchase Order year end close carry forward is reviving cancelled lines and setting the value OPEN_ in the COSTCONTROLTRANSCOMMITTEDCOST incorrectly to true 
4013038 DAXSE\SCM\CRM\Activities Creating new Appointments, Events or Tasks makes smmActivities form open with average speed of 2 minutes when having considerable amount of smmActivities records in the system. 
4013038 DAXSE\SCM\CRM\Activities Creating new Appointments, Events or Tasks makes smmActivities form open with average speed of 2 minutes when having considerable amount of smmActivities records in the system. 
4012438 DAXSE\SCM\Inventory Costing The Constant line is not estimated correctly in batch order when we add it manually 
4014359 DAXSE\SCM\Inventory Costing\Cost Module\Inventory Closing Inventory closing – Incorrect adjustment made 
3212562 DAXSE\SCM\Planning\Master Planning Positive days does not work correctly for intermediate product in Planned order 
4013921 DAXSE\SCM\Planning\Master Planning “Cannot delete a record” error when firming consolidated batch orders after applying hotfix KB3190607 
4013632 DAXSE\SCM\Procurement\Intercompany You will receive the error during Invoice posting in Direct Delivery Intercompany Scenarios: No cost rollup is found for this item.  Activate the Item Cost Price. 
4014435 DAXSE\SCM\Procurement\Intercompany Intercompany return warehouses are out of sync 
4014829 DAXSE\SCM\Product\Product Configuration Microsoft Dynamics AX client hangs when trying to re-configure a sales order line. 
4015355 DAXSE\SCM\Production and Shop Floor Electronic timecard creates double registrations 
4015714 DAXSE\SCM\Production and Shop Floor\Shop Floor Control\Production Integration Picking list and Report as finished quantities are incorrect after Report feedback with Error quantities on Job registration form 
4013926 DAXSE\SCM\Production and Shop Floor\Shop Floor Control\Time and Attendance Absence registration setup cannot be modified in Approval form – complementary fix to KB3070541. 
4013926 DAXSE\SCM\Production and Shop Floor\Shop Floor Control\Time and Attendance Absence registration setup cannot be modified in Approval form – complementary fix to KB3070541. 
4014430 DAXSE\SCM\Production Costing\BOM Calculation BOM/Route number on BOM calculation dialog does not change when selecting a different Style. 
4013919 DAXSE\SCM\Resource and Activity\Engineering Change\BOM Inaccurate licensing as BOMConsistOfReport and BOMPartOfReport are listed as Enterprise instead of Functional under the “ViewUserLicense” and “MaintainUserLicense” properties 
4014318 DAXSE\SCM\Resource and Activity\Engineering Change\BOM Maintain resource requirements wizard – run to replace resource A with resource B in routes 
4015011 DAXSE\SCM\Resource and Activity\Engineering Change\BOM Style dimension missing from BOM drop down lists 
4012905 DAXSE\SCM\Sales\Sales Orders When un-posting a previously registered item, AX reset the Net Amount field to 0.00. 
4012905 DAXSE\SCM\Sales\Sales Orders When un-posting a previously registered item, AX reset the Net Amount field to 0.00. 
4014989 DAXSE\SCM\Sales\Sales Orders Same Batch Selection – Credit Note gives Error “QTY must be positive for same lot reservation” for R3 
4015228 DAXSE\SCM\Sales\Sales Orders Case awaiting SE FTE review of investigation result – Use of Late selection when posting packing slip can result in that AX ignores not stocked products. 
4015585 DAXSE\SCM\Sales\Sales Orders Country showing as ‘%1’ in sales order and Shipments 
4015450 DAXSE\SCM\Warehouse and Transportation Performance: Poor query plan causes performance issue on Automatic Release to warehouse of Sales Orders 
4015008 DAXSE\SCM\Warehouse and Transportation\Warehouse Management Location X does not allow for mixed items error when overriding location during put-away and the same location exists in multiple warehouses 
4015170 DAXSE\SCM\Warehouse and Transportation\Warehouse Management Backport 3741399 to AX 2012 R3: Purchase order line receiving can receive incorrect lines when some inventory on the order is registered. 
4013920 DAXSE\SCM\Warehouse and Transportation\Warehouse Management\Picking and Putaway Unable to release SO when Replenishment line sequence number is specified in Location Directive 
4014133 DAXSE\SCM\Warehouse and Transportation\Warehouse Management\Work and Worker Management Movement by template suggest location not allowed mixed batches 
4014534 DAXSE\SCM\Warehouse and Transportation\Warehouse Management\Work and Worker Management Dimension tracking records are not cleaned up 
4015020 DAXSE\SCM\Warehouse and Transportation\Warehouse Management\Work and Worker Management When Purchase Put-away work is ‘In Process’ and the Mobile Device User needs to temporarily cancel out of the Putaway work, “Invalid WorkID” error will be received when attempting to complete putaway work 
4013750 DAXSE\Server Custom number sequence does not match format error in NumberSeq.numCheckFormat 
4013983 DAXSE\Server\AOS Service Follow-up on DAXSE 1721581 and AX6 198793 – Crash is not resolved 
4014060 DAXSE\Server\AOS Service Backport request DAXSE 3729680 to 2009 – Intermediate AOS crash with RPC exception after “promptOnClient 
4011945 DAXSE\SI\Project Accounting DISA upgrade AX 4.0 to AX 2012 R3:  UPGRADE SCRIPT UPDATEPROJITEMTRANS 
4012624 DAXSE\SI\Project Accounting DISA upgrade AX 4.0 to AX 2012 R3:  UPGRADE SCRIPT updateProjTransPostingPayment 
4012176 DAXSE\SI\Project Accounting\Adjustments Wrong transaction amounts after adjustment of an item requirement with a stocked service item 
4014758 DAXSE\SI\Project Accounting\Budget and Forecast Incorrect project budget balance after installing KB 3216671 
4012780 DAXSE\SI\Project Accounting\Estimates Project estimates not including adjusted transactions 
4014966 DAXSE\SI\Project Accounting\FIM Integration Project free text invoice not taking the exchange rate from Project contract id – Fixed rate agreement 
4014090 DAXSE\SI\Project Accounting\Indirect Costs Wrong data in report ‘Category actual transactions’ after KB3101732 
4014089 DAXSE\SI\Project Accounting\Journals Project hours journal cannot be posted when period in hold 
4014965 DAXSE\SI\Project Accounting\Project Control Incorrect Line limit when exporting Project Statement with multiple lines to Office 2007+ 
4015393 DAXSE\SI\Project Management\Activities When removing a WBS task the system is changing the cost price of other existing task  
4013800 DAXSE\SI\Project Management\Reports Cost control export by Project Group to Excel drops Vendor dimension when using ‘Expense’ Project category types in correlating Purchase Order Line 
4014091 DAXSE\SI\Project Timesheet ‘Allow date corrections on timesheets’ does not apply towards the adjustment of already posted Project Timesheets 

 

Production Order – RAF feedback missign from last operation

$
0
0
When you try to post a report as finished journal on a production order and you get the message “Total good quantity reported as finished for the production will be x. Feedback for the last operation...(read more)

Setting up a quality test group

$
0
0
When you are managing inventory or production there maybe times where you need to test the quality of a product. This could range from a simple inspection to an advanced sequence of test through a laboratory...(read more)

Issue resolved - Unsynced records from Retail store to AX DB (P-0001 job)

$
0
0
Sometimes even though we work with the same Dynamics AX product and architecture, we encounter some issues which could be tricky to solve. I had a similar issue with Retail architecture. The issue was...(read more)

Quality association to a production order

$
0
0
If you are producing goods you might want to inspect them as a quality check. This could be manual. But if you need a document to trigger the recording of the action then you can use the quality order...(read more)

Production RAF – Manual Registration

$
0
0
When you drive production with AX you could design your process in many different ways depending on how you work. The flexibility with the journals concept of updating productions means you driver your...(read more)

Data manipulation tip 1 In Dynamics ax 2012 and D365 Of Operations Data copy method.

$
0
0

 

Currently I am doing Report development project, I got some tips for Data manipulation , these tips I recently learned.

 

Copy data from one table buffer to other of same type.

 

 

During report development, We usually populate  temp table with result of Query execution. Usually we need copy of same data for aggregate functions.

 

Instead map each field of buffer with each other. We can copy the whole data by using .data method.

 

 

Suppose we have custom temp table CustSaleQtyTmp which we need to copy from one buffer to other.

class DataManipulationJob
{
/// <summary>
/// Runs the class with the specified arguments.
/// </summary>
/// <param name = "_args">The specified arguments.</param>
public static void main(Args _args)
{

CustSaleQtytmp _temp1,_temp2;
_temp1.IntQty=100;
_temp1.CustAccount =”Cust00001″;
_temp1.insert();
_temp1.IntQty=200;
_temp1.CustAccount =”Cust00002″;
_temp1.insert();

_temp1.IntQty=300;
_temp1.CustAccount =”Cust00003″;
_temp1.insert();
while select * from _temp1
{
// Instead copy like this we can use Data method
// _temp1.CustAccount = _temp2.CustAccount;
// _temp1.IntQty = _temp2.IntQty;

_temp2.data(_temp1);
_temp2.insert();

}

while select * from _temp2
{
info( ” _temp2 with ” + _temp2.CustAccount + ” ” + int2Str(_temp2.IntQty));

}
}

}

output like

Viewing all 17314 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>