Strange error:sumindexfield in non decimal field??

txerifftxeriff Member Posts: 501
Hi Mates,

I hope some1 can help. I´m migrating some code and I get the following error. No clue using debugger or compiling code. I checked if there is any setcurrentkey somewhere, no clue.

thx!
1.png 6.4K

Best Answer

  • txerifftxeriff Member Posts: 501
    edited 2018-03-15 Answer ✓
    Hi Mates,

    I have been busy.

    Sorry for disturbing you. It was another field, it was trying to make sum over a "document no.". perhaps when this database was created field numbers "jumped" over the others and thats why. Changed that calcfield formula and good. It is difficult to find it when you are migrating code you haven´t developed+objects that are there...


    thanks!

Answers

  • Slawek_GuzekSlawek_Guzek Member Posts: 1,690
    Are you trying to add up the content of "Document No." ?
    Slawek Guzek
    Dynamics NAV, MS SQL Server, Wherescape RED;
    PRINCE2 Practitioner - License GR657010572SG
    GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
  • txerifftxeriff Member Posts: 501
    Are you trying to add up the content of "Document No." ?

    To be honest, I dont think so.
  • Slawek_GuzekSlawek_Guzek Member Posts: 1,690
    Can you post the flowfield definition here?
    Slawek Guzek
    Dynamics NAV, MS SQL Server, Wherescape RED;
    PRINCE2 Practitioner - License GR657010572SG
    GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
  • txerifftxeriff Member Posts: 501
    Can you post the flowfield definition here?
    Hi Mate,

    i´ve been busy. I went back to this issue. Seems like its this field but, in another database, works like a charm. I´ve checked keys and field type, nothing.


    1.png 11.8K
  • Slawek_GuzekSlawek_Guzek Member Posts: 1,690
    It's time to DBCC CHECKDB me thinks.. or disable maintenance on all SIFT indexes on the Sales Invoice Line and re-enable them to get all SIFT views rebuild.
    Slawek Guzek
    Dynamics NAV, MS SQL Server, Wherescape RED;
    PRINCE2 Practitioner - License GR657010572SG
    GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03
  • afarrafarr Member Posts: 287
    Slawek's suggestion is probably more useful, but here are some questions that just might help.

    You said that you're migrating some code.
    Are you exporting objects from one database, and importing them into another database?
    Are you exporting them as .fob or .txt ?

    Check the field numbers of all fields involved:
    your flowfield (in the Sales Invoice Header)
    "Another Withholding Amount" (in the Sales Invoice Line)
    "No."
    "Document No."

    Do the field numbers in the source database conflict with other field numbers in the target database?
    Alastair Farrugia
  • txerifftxeriff Member Posts: 501
    Hi Friends,

    thanks, for advices. I checked and tried to remove sift indexes, enable again. nothing. Problem is definetily in the flowfield. I also tried before, recreating it, but nothing.

    No clue why it has such behaviour.


    Im merging code but manually, copy and paste pieces of code. For that table seems I changed nothing at all.
  • afarrafarr Member Posts: 287
    1. In the "problem database", I would export the "Sales Invoice Header" and "Sales Invoice Line" tables as .txt, and check where "Document No." and "Another withholding amount" are mentioned.

    2. You said that the flowfield works well in another database (call it the "good database").
    Does each field have the same field number in the "good database" and the "problem database"?

    3. Are you using the same licence in both databases? (I'm not sure how a different licence would lead to this error, I'm just mentioning "wild ideas".)
    Alastair Farrugia
  • txerifftxeriff Member Posts: 501
    edited 2018-03-15 Answer ✓
    Hi Mates,

    I have been busy.

    Sorry for disturbing you. It was another field, it was trying to make sum over a "document no.". perhaps when this database was created field numbers "jumped" over the others and thats why. Changed that calcfield formula and good. It is difficult to find it when you are migrating code you haven´t developed+objects that are there...


    thanks!
  • afarrafarr Member Posts: 287
    It's good to know that you found the source of the problem.
    Please mark this as solved in mibuso.

    Thanks
    Alastair Farrugia
  • AppJettyAppJetty Member Posts: 2
    Its the perfect solution, was confusing a bit but one can get the solution at last and the lst query was will it work for the rest of the times or we need to keep it updating again and again ?
Sign In or Register to comment.