General Variables (Parameters)

It is used in Netigma definitions that can take parametric values such as global variables, additional query criteria, operations etc. 

UsageOutputDescription

{T@ALANADI/format:p1,p2,p3,p4}

 

p1: veri Tipi :DateTime, Int32 , ... etc:  

http://msdn.microsoft.com/query/dev10.query?appId=Dev10IDEF1&l=tr-TR&k=k(SYSTEM.TYPECODE);k(TargetFrameworkMoniker-%22.NETFRAMEWORK%2cVERSION%3dV3.5%22);k(DevLang-CSHARP)&rd=true

p2: input culture :en-US, tr-TR , ....

p3: output culture :en-US, tr-TR , ....

P4: format string: if dateTime which receives the format string supported by the data type produces eg dd/MM/yyyy 25/06/2015. The format string must be supported by the data type. Otherwise the result is not produced

{T@BINA_ALAN/format: Double,en-US,tr-TR, 00.0}

123.5

Many double formatter can be used. 

http://www.csharp-examples.net/string-format-double
{T@BINA_ALAN/format: Double, , , 00.0 }123.5

Culture knowledge can be left blank. In this case the current culture is used.

{T@KAYIT_TARIH/format: DateTime, , , d/M/yyyy HH:mm:ss }

9/3/2008 16:05:07

Many date formatters are available. 

http://www.csharp-examples.net/string-format-datetime/

{T@IL_ADI/toupper}

ANKARACapitalizes all letters.

{T@IL_ADI/lower}

ankaraConverts all letters to lower case.
{T@IL_ID/Lookup}ankaraReturns the lookup value of the column.

htmlencode(<br></br>)

&lt;br&gt;&lt;/br&gt 

htmldecode(&lt;br&gt;&lt;/br&gt)

<br></br> 

urlencode(http://netcad.com.tr)

http%3A%2F%2Fnetcad.com.tr

 

urldecode(http%3A%2F%2Fnetcad.com.tr)

http://netcad.com.tr 

{Application}

"Application name" 
{Session}"Session ID" 
{USER} "Active user code" 
{USERNAME}"Active user name" 

{USER@IL_ID}

"Active user Province code" 
{USER@IL_AD}"Active user province name"  

{USER@ILCE_ID}

"Active user district code" 

{USER@ILCE_SIRA}

"Active user county order" 

{USER@ILCE_AD}

"Active user county name"

 
{USERGROUP}Active user group1, active user group2, active user group3 
{A@Key} "True/ False"{A@xxxx} Whether it has xxx authority  (isValid)
{P@Key}"Value of the parameter named Key in parameter server" 

{FORM@Key} 

"The value of the key named form element. (Request.Form["Key"])" 

{Q@Key}

"Value of key named parameter in query string" 
{U@Key} 

The Authorization manager's SetUserState method is used to set a state for the current user. 

Example: this.Authorization.SetState ("DefaultLanguage", "tr") ...etc. If there is a value set in this way 

Eg {U @ DefaultLanguage} returns the current user's language setting. 

{LANGUAGE}Selected language codeReturns the ISO language code of tr for Turkish and 2 for English.
{CULTURE}Selected culture knowledgeTr-TR returns the entire code of the language as en-US.
{NOW} Instant time information for Sql

! is used to give a parameter to database queries. The time information turns into a parameter according to the database being connected. 

 

Example:  

{NOW}  For oracle it converts to >> TO_DATE('" + DateTime.Now.ToString("yyyyMMdd HH:mm:ss") + "','YYYYMMDD HH24:MI:SS'

{DB@...}

 

 

 

Returns the value according to the parameters given from the database. 

 

Expression: {DB@IL[OBJECTID=6].ADI}

Output: ANKARA

Netigma 4+

{DB@IL[OBJECTID=6].ADI} returns the ADI field of the record with OBJECTID field 1 in the PROVINCE table by querying VT.

 

Sample-1

{DB @KULLANICI [KODU={user}].BIRIMID}

expression,

On the USER table 

CODE = active user code with {USER} 

Record the value in column BIRIMID. 

 

Sample-2:

{DB@KULLANICI[KODU IN (1,2,3)].BIRIMID}

expression,

converts the BIRIMID values of the records

On the USER table with the

CODE fields 1,2 and 3

as coma seperated

 

Sample-3:

{DB@Employees[EmployeeID IN (7,8)].Orders[CustomerID LIKE '%a%'].Total}

expression,

merges the Employees ve Orders tables based on the relation of meta,

converts the records having Employee ID 7,8 in the Employees table and the ones containing “a” in its CustomerID

in the Orders table as coma seperated.

When added to the query's criteria, the query that goes to the database is added as a query, not as a value.

{NOW.DATE} Instant short historyAnin returns the knowledge of the day, month, and year as a short date text. Example: 12/22/2016
{NOW.DATETIME} Instant long history informationAnin returns the knowledge of the day, month, and year as long date text. Example: 22.12.2016 18:21