Web Reporting Tools Finereport usage Summary of common functions (report functions)

Source: Internet
Author: User
Tags rowcount

Note: In this summary, usually TableName or viewname as the parameter factor. Functions are invoked in the order in which they are first looked up from the private data source and then looked up from the public data source.

CLASS

Class (object): Returns the class to which the object objects belong.


Cnmoney

Cnmoney (Number,unit) returns the capitalization of the renminbi.

Number: Numbers of numeric types that need to be converted.

Unit: Units, "S", "B", "Q", "W", "SW", "BW", "QW", "Y", "sy", "by", "QY", "WY" respectively represent "pick up", "Bai", "Qian", "Million", "Pick million", "Bai million", "Thousand Million", "billion", "Hundred Million", "Bai billion" , "Thousand billion", "trillion".

Note:

The unit can be empty, and if it is empty, the number is converted directly to the renminbi, otherwise the number is multiplied by the unit's binary, and then the result of the multiplication is converted to renminbi capitalization.

Example:

Cnmoney (1200) is equal to one thousand Bai round.

Cnmoney (12.5, "w") is equal to one of the thousand woods.

Cnmoney (56.3478, "bw") is equal to the million Lu Bai three hundred thousand hundred Ba Bai round whole.

Cnmoney (3.4567, "y") is equal to three billion, Wu Bai Lu qi million round the whole.


COL

COL () Returns the column number of the current cell.

Example:

If the current cell is A5, writing "=col ()" In A5 returns 1.

If the current cell is C6, writing "=col ()" In C6 returns 3.


ColCount

ColCount (Tabledata): Returns the number of columns in the Tabledata.

Tabledata:tabledata's name, in string form.

Note:

Look in the private data source first, and then from the public data source, and return the number of columns in the first found Tabledata.

Example:

Take the data source Frdemo we provide as an example

ColCount ("Check") equals 6.

ColCount ("Country") equals 5.


ColName

ColName (Tabledata,colindex) returns the column name of the column ordinal colindex in Tabledata.

Tabledata: Represents the name of Tabledata, in string form.

Colindex: Indicates the column ordinal.

Note:

Tabledata is first looked up from the private data source and then from the public data source.

Example:

ColName ("Check", 3) equals Accename.

ColName ("Country", 4) equals area.


Eval

EVAL (exp): Returns the result of an expression exp calculation.

Exp: An expression-form string.

Note:

As long as the parameter exp in the eval can eventually be converted into a string in the form of an expression, such as "sum (2,4)", "2+7" and so on, then it can be computed.

Example:

EVAL ("2+5") equals 7.

EVAL ("Count (2,3)") equals 2.

EVAL ("Sum" + "(2,3,5)") equals 10.

EVAL (IF (True, "sum", "count") + "(1,2,3,4)") equals 10.

EVAL (IF (False, "sum", "count") + "(1,2,3,4)") equals 4.


Fields

Fields (Connectionname,tablename): Returns tableName all field names in this table.

Example:

The contents of a table named task in the database base are as follows:

Namestart End

A2008 2009

B2009 2012

Then fields ("BASE", "task") equals [Name,start,end].


FORMAT

Format (Object,format): Returns the format of object.

Object: It needs to be formatted with a string, number, object (usually with date, time).

Format: the formatted style.

Note:

The case in this format must be in strict accordance with the rules in the example above, month: uppercase mm, Year lowercase: yyyy or yy, servings: lowercase dd.

The format used here as a parameter factor can also be referenced with "."

Example:

Format (Today (), ' yyyy-mm-dd ') results 2008-11-01


Inmap

Inmap (Key,value, mapName): Determines whether the data dictionary mapName contains a data pair with a key value of value. The return value is of type Boolean. There is a return of true, no return false.

Key: The detected key.

Value: The value detected.

MapName: The specified data dictionary name.

Note:

The mapname must be of type string.

Example:

Inmap ("Customerdic") returns Boolean.true (Boolean).


ISNULL

ISNULL (object): Determines whether all the values in the object are all primitive.null.


MAP

MAP (Key,mapname): Returns the value corresponding to the key in the data dictionary named MapName.

Key: The key in the data dictionary corresponding to the return value.

MapName: Specify the data dictionary name, and note that the data dictionary name should be quoted

Example:

MAP (1, "CustomerName") equals "Yixing Hongdafood Co."


RECORDS

RECORDS (Connection,table,field): Returns all the elements under field names in the table in database tables.

Example:

The contents of a table named task in the database base are as follows:

Namestart End

A2008 2009

B2009 2012

Then records ("BASE", "task", "End") equals [2009,2012].

RECORDS (Connection,table,field,row) returns the record of row row below the Field field in table, field can be a column name or a column number.

RECORDS ("BASE", "task", "End", 2) equals 2012.

RECORDS ("BASE", "task", 2,2) equals 2009.


REVERSE

REVERSE (value): Returns the logical value opposite to value.

Example:

REVERSE (True) equals false.


ROW

Row () returns the line number of the current cell

Example:

If the current cell is A5, writing "=row ()" In A5 returns 5.

If the current cell is B8, writing "=row ()" in B8 returns 8.


ROWCOUNT

ROWCOUNT (Tabledata) returns the number of rows for tabledata.

Tabledata:tabledata's name, in string form.

Note:

The number of tabledata rows is returned from the private data source before it is looked up from the public data source.

Example:

Take the data source Frdemo we provide as an example

ROWCOUNT ("Check") equals 3.

ROWCOUNT ("Country") equals 18.


Tabledatafields

Tabledatafields (Tabledata): Returns all the field names in the Tabledata.

Note:

Look in the report dataset first, and then from the server dataset, and return an array of tabledata column names.

Example:

Tabledatafields ("Country") equals [name, capital, continent, area, population


Tabledates

Tabledatas (): Returns the report dataset and server data set name. ]

Example:

The server datasets are: DS1,DS2,DS3; The report dataset has DSR1,DSR2.

Tabledatas () equals [DSR1,DSR2,DS1,DS2,DS3].

The Tabledatas (0) returns the server dataset name; Tabledatas (1) Returns the name of the report data set;

Tabledatas (0) equals [DS1,DS2,DS3]; Tabledatas (1) equals [DSR1,DSR2].


TABLES

Tableas (ConnectionName): Returns all the table names in the database named ConnectionName.

Example:

Assume that there are 3 tables in the Frdemo database: a,b,c;

Then tables ("Frdemo") equals [A,b,c].


VALUE

Value (Tabledata,row,col) returns the Tabledata line number as row with the column number Col.

Tabledata:tabledata's name, in string form.

Row: line number.

Col: column number.

Note:

Look in the private data source first, and then from the public data source, and return the Tabledata qualified value.

Example:

VALUE ("Country", 5, 3) equals South America.

VALUE ("Simple", 8, 3) equals Jonnason.

Web Reporting Tools Finereport usage Summary of common functions (report functions)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.