Options

Wrong flowfield sum

JedrzejTJedrzejT Member Posts: 267
Hi.

SQL database

I havea flowfield in header table and it calculate sum of quantity form lines table.

On header i see 985,19
When i drilldown flowfield i see 3 position (sum is 735,13)
985,19 - 735,13 = 250,06
I know customer delete line with this value from Lines table few days ago.
I search table manual and don't find this record.
There is no code in table and form at this field

I have code in OnAfterGetRecord:
SETFILTER("Num. state filter",'>%1&<=%2',"Numerator state D","Numerator state R");

I set filter on flowfilter on which based my "bad sum" flowfield
When we work on native everythink be alright

Anyone know this problem?
Thanks for reply

Comments

  • Options
    pindevpindev Member Posts: 22
    Hi,
    you question actually contains the answer
    " I know customer delete line with this value from Lines table few days ago. "
    Do not let the customers access tables straight from the object designer(neither from any SQL utility) and you won't have troubles with the flowfields.
  • Options
    JedrzejTJedrzejT Member Posts: 267
    Customer delete that lines normally..form program. F4 he can do that.. this is not posted document. Sorry if you don't understund me.

    I test this situation on my workstation now.
    Unfortunately navision do the same. Flowfield calculate wrong sum.
    I think i stuck on this some time..
  • Options
    JedrzejTJedrzejT Member Posts: 267
    Solved temporary

    Testing that table says SIFT table of that table has error
    I don't know how this happen (i would like to know)
    I copy keys and sumindex field,Delete,Paste again

    SIFT is ok.

    Regards
  • Options
    kinekine Member Posts: 12,562
    Version of Navision?

    Try to optimize the table, SIFT tables will be recreated...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    JedrzejTJedrzejT Member Posts: 267
    I use version 4 SP1
    First time my SIFT tables goes wrong.. i have on my mind that Optimize functionality correct this too :oops:

    Thanks
  • Options
    JedrzejTJedrzejT Member Posts: 267
    Not good. Optimalization doesn't correct this.

    Testing the table says :

    "Error: The Departure cost line table has inconsistent SumIndexField values: Key fields: 1,2,3,4,5,6,7 SumIndexField table: Navision - companyname_$50031$0 Contact your system manager.

    Optimalization recreate the index? Otimalization time is about 5 second. Delete all keys and paste again work few minutes (this solution correct sumindexfields in this case)
  • Options
    JedrzejTJedrzejT Member Posts: 267
    This problem comes again

    In one week 3 tables(sumindex) crashes. I think they would crash again. Optimalization don't correct this.

    The weird thing is. When i create backup with wrong sift tables and restore it on other machine the SIFT tables still have incosistency. As I know restore create index again.
    Only cut keys/save table/paste keys/save correct this.

    The heck is that all tables which have bad flowfields sum are in custom functionality (for today, maybe this is fortuity maybe not). Everything work fine since we migrate to SQL2005. Is there are some special needs for sql? Special coding or .. i really don't have idea.

    We use Nav4.0 Sp1. Thanks for any hint.
Sign In or Register to comment.