Home > database >  Dynamic calculation formula how to achieve! !!!!!!!!! Implement a custom indicators and statistical
Dynamic calculation formula how to achieve! !!!!!!!!! Implement a custom indicators and statistical

Time:10-08



Such as formula:
((table 1. The column of table 1 + 1. Column 2) * table 2. Column 1-0.25)/300 + table 3. The column 4
The dynamic implementation


Is to give customers with formula but behind-the-scenes formula of calculating

Indicators in this picture represents a column in the table

Rookie newcomers seek counsel!

CodePudding user response:

We have to do is to replace it

CodePudding user response:

How to replace! Just a job
Foundation is weak

CodePudding user response:

reference 1st floor acen_chen response:
just replace it


How to replace!

CodePudding user response:

Column name and product description must have corresponding ah, replace the product description for the column name is constitutes the executable SQL or formula

CodePudding user response:

Mainly use the describe and evaluate these two functions to do this, you can refer to

https://wenku.baidu.com/view/74f942fc910ef12d2af9e77b.html

Etc have time I write an example

CodePudding user response:

Predecessors upstairs really can write example

CodePudding user response:

Acen_chen

Can you explain it specifically how to implement

CodePudding user response:

For many years no, some don't remember, you use a variable or write a corresponding Chinese name corresponding to the table and column names, judged by catch statement, will do

CodePudding user response:

Remember to write the calculation of wage demands, financial front desk design formula, the basic principle is to replace, and then running database

CodePudding user response:

Moderator said truth, the dw. The Describe () 'evaluate'

CodePudding user response:

references 9 f wzh502887976 response:
remember to write the calculation of wage demands, financial front desk design formula, the basic principle is to replace, and run database
can specifically talk about ideas

CodePudding user response:

reference class 11 floor door fish response:
Quote: references 9 f wzh502887976 response:
remember to write the calculation of wage demands, financial front desk design formula, the basic principle is to replace, and run database
can specifically talk about ideas?


DW create a computed field, computed columns,

Computed columns can refer to the column, add operation,
By dw. The Describe (' evaluate '), you can dynamically modify the expression of the computed columns in a script,
In order to achieve the effect of a user-defined formula

CodePudding user response:



Button is clicked event
 string ls_temp 
Ls_temp=trim (mle_1. Text)
St_2. Text="is the results:" + dw_1. The Describe (" the Evaluate (' "+ ls_temp +", "+ ddlb_1. Text +") ")


According to expression support syntax, can realize the dynamic formula
  • Related