Solved

Behavior of Line Number for INTran DAC not usual

  • 22 June 2023
  • 6 replies
  • 43 views

Userlevel 2
Badge

I am working with INTran DAC. I need to use its LineNbr field, but I am not able to predict how LineNbr is generated for this DAC. I created this Issue which has 5 line items.

 

 

But when I am checking the Database it looks something like this.
 

SQL Database Data



I am not sure is happening can anyone help with this thing.

Thanks

icon

Best answer by aaghaei 22 June 2023, 17:36

View original

6 replies

Userlevel 7
Badge +8

With PXLineNumber the number will only be sequential if no line is deleted from the document lines. The counter is kept on the document header DAC and is incremental. 

Userlevel 2
Badge

@aaghaei  I know that part. I have not deleted any line item while creating this document. 

Userlevel 7
Badge +8

I am not so sure about no line is deleted. Any time + is clicked in grid or a line is been added by line feeder, a new sequence is being added whether you save or not. It considered InsertedDeleted in record statuses. Not sure what you are going to do but this sequence is serving as an element in PK and should not be used for any other purposes.

Userlevel 2
Badge

@aaghaei If only two times + is clicked them also the Line Nbr and 1 and 3. I request you try that on your system and check if it behaves the same or different. I want to fetch data on other screen based on line number and this un-predicted behavior is not letting me do that.

Thanks

Userlevel 7
Badge +8

I have developed codes on multiple custom screens and it behaves as designed. For sorting or fetching purpose however if it is 1 6 9 won’t make any difference. I am not sure with this kind of vague question without any context anyone can be helpful. 

Userlevel 7
Badge

Hi @param2022 were you able to find a solution? Thank you!

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved