Hi everybody!
I was browsing through this forum for some time but I didn't find a helpful hint to a solution concerning my problem.
I have a Navision-SQL-Database and I'm using Microsoft Dynamics NAV 4.0 SP2.
Retrieving the values of FlowFields (SIFTs) by using the "N/ODBC" in a Native-environment is no problem but as I have an SQL-Database I've to use the SQL-Server-ODBC-Driver.
How can I access the value of FlowFields via SQL as those Fields are like "virtual" and can't be seen when I look at the definition of the Table via the SQL Server Enterprise Manager or the SQL Server Managament Studio.
Is there a kind of "how to"-instruction to solve my problem and also get the FlowField-values by the use of the SQL-ODBC-Driver?
Thank you!
Regards,
Jonny
0
Comments
Unfortunately in SQL the fields don't get stored in the table definition. For each Index that has SumIndexFields set to be maintained an extra table is created that stores the values for each combination of IndexKeys. When a flowfield is told to be calculated it reads this SIFT Table and sets filters so it reads from the correct buckets.
You can either copy the behaviour of what Navision does when it calls SQL (ie read the SIFT Table) or you can SUM directly from the table that the flowfield is based upon.
Regards,
Amer
I never said it would be simple
But once you know which SIFT Table to read and the fields that make up the table in question, it should be entirely possible to read the correct values. Unless of course the structure of the table is likely to change which could throw a spanner in the works.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
If you have Case 1 it would be possible to avoid SUM but because of Case 2 when you don't have precalculated rows for every possible key value set, SUM is therefore always used.
Regards,
Amer
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!