Search Results for query

 

 

 

 

 

 

 

MoveQuery

Takes two parameters, DestinationQuery, SourceQuery

 

NewEComQuery

Takes one parameter, QueryName

 

LookupQuery

Takes six parameters, DestQuery, SourceQuery, DestDestFld, DestXFld, DestYFld, SourceYFld

 

JoinQuery

Takes 5 parameters, DestinationQuery, SourceQuery, DestinationMatchField, SourceMatchField, Mode

 

Public Method WorkQuery Example

In this example, you will see how to use a public method that works on or with the current WorkQuery that you pass into the method.

 

MapQuery

Takes five parameters, DestQuery, SourceQuery, SourceXFld, SourceYFld, SourceZFld

 

CopyQuery

Takes two parameters, destinationQuery, sourceQuery

 

WorkQuery

Takes one parameter, QueryName

 

DeleteQuery

Takes one parameter, the name of the query

 

[Pull] List of Fields from another Query

Takes three parameters, QueryName, FieldBase, FieldNames

 

AppendQuery

Takes 3 parameters, DestinationQuery, SourceQuery, bMoveIt

 

NewQuery

Takes 3 parameters, QueryName, SourceQuery, bWork

 

Query Based Routing Example

For small and simple procedures that are not expected to grow in complexity over time, simple routing based on URL parameter values from a [Pull] directly from the Request query is sufficient and requires less code. For complex procedures that are expected to grow and evolve over time, a larger more robust foundation for the routing should be used.

 

TopQuery

Takes one parameter, FieldBase

 

[!] Assert (Top Query)

Parameter is a comma separated list (using CSV rules and not in quotes) of the fixed hard coded values to select from

 

[L] Lookup (Top Query)

Takes one parameter.

 

[Date] (Top Query)

Has no parameters

 

[$] Currency (Top Query)

Takes one parameter, Source

 

[Ensure] Field Exists

Takes a variable number of parameters, a comma separated list of TopQuery variable names

 

 

Foreign

Takes a single parameter, a QueryName

 

ForEach

Takes a variable number of parameters, QueryName, MethodName, [Param1, [Param2, etc...]]

 

[#] Format (Top Query)

Takes 1 parameter, a formatting mask

 

[If] Assignment (Top Query)

Parameter is divided into two parts, the Test and the Result if True. The test comes prior to the keyword of Then and the Result if True comes after.

 

Using the Backtick `

Some Work Query command parameters can accept a source of either a Work Query Field name or a text literal. Text literals in these cases are prefixed with a backtick ` character.

 

Trigger

Takes two parameter, URL, InputQuery

 

 

[DateTime] (Top Query)

Has no parameters

 

 

Remote

Takes three parameters, Url, InputQuery, OutputQuery

 

ProcECom

Takes one parameter, QueryName

 

PaaS

Takes three parameters, Url, SaaSTenant, InputQuery, OutputQuery

 

[Time] (Top Query)

Has no parameters

 

[_$] Currency if not blank (Top Query)

Has no parameters. If the field is blank it will remain blank.

 

[_#] Format if not blank (Top Query)

Takes 1 parameter, a formatting mask

 

[ ? ] Pick First (Top Query)

Parameter is a space separated list of fields to choose from

 

CopyFirst

Takes two parameters, DestinationQuery, SourceQuery

 

Pull

Takes three parameters, QueryName, FieldBase, FieldNames

 

CopyUnique

Takes four parameters, DestinationQuery, SourceQuery, UniqueField, UniqueValue

 

QBox

Takes two parameters, QueryName, Title

 

Detach

Takes 3 parameters, ParentTableName, ChildTableName, and a boolean expression (optional)

 

Children

Takes two parameters, ChildTableName, Mode

 

ChildrenAlias

Takes two parameters, ChildTableName, Mode

 

Delete

Takes two parameters, TableName and a boolean expression

 

Get

Takes two parameters, TableName, IfLenFld

 

ListRltns

Takes one parameter, TableName

 

ListTables

Has no parameters

 

ListProcs

Takes one parameter, TableName

 

JsonEmbed

Has six parameters, UniqueParent, DestField, FieldBase, UniqueChild, EmbedFields, Options

 

ListFields

Takes one parameter, TableName

 

HttpCookie

Takes 6 parameters, Name, Value, Path, Domain, Expires, Other

 

JsonStream

Takes two parameters, Data, Options

 

HtmlBlock / End HtmlBlock

Takes two parameters, Location, Mode

 

TimeZone$

Takes two parameters, Source, Value

 

WebSafe$

Takes one parameter, Source

 

HttpHeader

Takes two parameters, name, value

 

Attach

Takes 3 parameters, ParentTableName, ChildTableName, IfLenFld

 

Backfill

Has no parameters

 

AppendTable

Takes one parameter, TableName

 

Raw

Takes one parameter, the contents of which are used for the HTTP Reply Body

 

TemplateType

Takes one parameter, Type

 

LoadRecord

Takes two parameters, TableName, RecordAlias

 

ETableStream

Takes two parameters, ExcelTableData, Options

 

UpdateOrNew

Takes two parameters, TableName, IfLenFld

 

Files

Takes 5 parameters, FieldBase, Destination, Action, Source, IfLenFld

 

Folders

Takes 5 parameters, FieldBase, FolderPath, Action, Source, IfLenFld

 

FixFields

Takes one parameter, a single character

 

EnsureNavFields

Takes two parameters, FieldBase, FieldNamesList

 

CsvStreamWS

Takes two parameters, CSVData, bNoHeaders

 

CsvStream

Takes two parameters, CSVData, bNoHeaders

 

DeleteFields

Takes two parameters, FieldBase, FieldNameList

 

EnsureFields

Takes two parameters, FieldBase, FieldNames

 

Discard

Has no parameters

 

New

Takes two parameters, TableName, IfLenFld

 

Parents

Takes three parameters, ChildTableName, ParentTableName, Mode

 

Lookup

Takes six parameters, FieldBase, Destination, Table, Alias, SourceField, IfLenFld

 

LoadTable

Takes one parameter, TableName

 

LoadTableFields

Takes one parameter, TableName

 

Images

Takes up to 6 parameters, FieldBase, Destination, Action, Source, Value, IfLenField

 

Search

Takes three parameters, TableName, SearchTerms, SearchInFields

 

Update

Takes two parameters, TableName, IfLenFld

 

Format

Takes five parameters, FieldBase, FieldList, Mask, bBlanks2Zero, IfLenFld

 

Group

Takes 7 parameters, FieldBase, GroupBy, GroupTotals, GrandTotals, Seperator, TotalPre, TotalPost

 

ParentsAlias

Takes three parameters, ChildTableName, ParentTableName, Mode

 

Sort

Takes two parameters, FieldBase, SortFieldList

 

SetNew

Takes four parameters, FieldBase, FieldName, Source, IfLenFld

 

SetEnsure

Takes two parameters, FieldName, Value

 

TabStream

Takes two parameters, Data, bHasHeader

 

WithAll

Takes five parameters, FieldBase, Destination, Action, Source, IfLenFld

 

Text

Takes six parameters, FieldBase, Destination, Function, Source, Value, IfLenFld

 

TabStreamWS

Takes two parameters, CSVData, bNoHeaders

 

SaveCsvFile

Takes two parameters, FilePath, bUseHeader

 

ResetFields

Takes two parameters, FieldBase, FieldNames

 

Reset

Takes no parameters.

 

SaveJsonFile

Takes two parameters, FileName, Options

 

SaveTabFile

Takes two parameters, FileName, bUseHeader

 

SaveRawFile

Takes two parameters, FileName, bUseHeaders

 

SaveNulFile

Takes two parameters, FileName, bUseHeader

 

HtmlNavbar

Takes 10 parameters, Location, Mode, Title, TitleLink, Class, Fixed, bUseContainer, bNotResponsive, bInverted, HtmlPre, HtmlApn

 

HtmlNav

Takes 7 parameters, Location, Mode, Title, TitleLink, Class, HtmlPre, HtmlApn

 

HtmlForm

Takes 6 parameters, Location, Mode, ActionLabel, ActionPath, Class, ActionMethod

 

HtmlRaw

Takes 3 parameters, Location, Mode, bWithNoHeader

 

Lang

Takes four parameters, FieldBase, Destination, Source, IfLenFld

 

HtmlTable

Takes 6 parameters, Location, Mode, Class, bNoHeader, bNoAutoAlign, bNoIDTags

 

HtmlTab

Takes 3 parameters, Location, Mode, bWithNoHeader

 

GetFieldDefs

Has no parameters.

 

XmlStream

Takes one parameter, Data

 

WithGroup

Takes six parameters, FieldBase, GroupByField, Destination, Action, Source, IfLenFld

 

HtmlBlocks / End HtmlBlocks

Takes two parameters, Location, Mode

 

HtmlETable

Takes 6 parameters, Location, Mode, Div, Data, Script, Extra

 

HtmlDTable

Takes 5 parameters, Location, Mode, Class/ID, Init, bNoAutoAlign

 

HtmlDropdown

Takes 5 parameters, Location, Mode, Title, Element, Class

 

ListFolders

Takes two parameters, FolderPath, bRecursive

 

ListFiles

Takes 3 parameters, Folder, Filter, bShowImgSize, bShowAccessed

 

KeepLast

Takes no parameters

 

ListQueries

Takes no parameters

 

LoadJsonFile

Takes two parameters, PathToFile, Options

 

LoadCsvFileWS

Takes two parameters, FileName, bHasHeader

 

LoadCsvFile

Takes two parameters, FileName, bHasHeader

 

KeepFor

Takes two parameters, FromIndex, ToIndex

 

KeepFirst

Takes no parameters

 

KeepFields

Takes two parameters, FieldBase, FieldNamesList

 

KeepIf

Takes 4 parameters, FieldBase, Left, Comparison, Right

 

KeepIfFound

Takes 3 parameters, FieldBase, Fields, SearchTerms

 

KeepIfAny

Takes a variable number of parameters, FieldBase, Test1, Test2, [etc...]

 

KeepIfAll

Takes a variable number of parameters, FieldBase, Test1, Test2, [etc..]

 

NewFields

Takes two parameters, FieldBase, FieldNames

 

MergeRecords

Takes 5 parameters, FieldBase, GroupBy, MergeField, Delimiter, bKeepBlanks

 

LoadTabFileWS

Takes two parameters, FileName, bHasHeader

 

NewRecords

Takes one parameter, QuantityToAdd

 

Pivot

Takes two parameters, FieldBase, PivotField

 

Offset

Takes 7 parameters, FieldBase, Destination, Source, OffsetVal, Operator, OpValue, IfLenFld

 

NulStream

Takes two parameters, Data, bHasHeader

 

LoadNulFile

Takes two parameters, FileName, bHasHeader

 

LoadMultipart

Takes two parameters, Data, Boundary

 

LoadMemUsage

Has no parameters

 

LoadPipeFileWS

Takes two parameters, FileName, bHasHeader

 

LoadTabFile

Takes two parameters, FileName, bHasHeader

 

LoadReqFile

Has no parameters

 

LoadRawFile

Takes one parameter, FilePath

 

TimeUnix$

Takes one parameter, Source

 

Meta

Takes any unspecified data, intended for use by external systems

 

Macro

A set of instructions that can be called with parameters to run in the current scope.

 

Method

Private Method contained within a given procedure.

 

Return

Takes a variable number of parameters.

 

OnError / End OnError

Takes one parameter, Control

 

Image

Has 4 parameters, Destination, Action, Source, Value

 

Folder

Takes three parameters, FolderPath, Action, Source

 

File

Takes three parameters, Destination, Action, Source

 

ForeignWith

Takes a single parameter, a FieldBase

 

If (Not) / Then

Takes a single Field name to test if it is true, with an optional Not operator to test if false, followed by the conditional statement

 

Function

A special type of Private Method, called a Private Function, that is intended to return a single value or multiple values simultaneously.

 

WorkWith

Takes one parameter, FieldBase

 

WorkIf

Takes one parameter, FieldName

 

Cloudflare Integration

Cloudflare is a first and foremost a Web Application Firewall and Content Distribution Network, among other additional services.

 

Moxie.cfg Config

The Moxie.cfg file is read on server start and controls aspects that cannot be changed while the server is running.

 

Command Line with .mox file

A .mox file, with MOX code in it, can be run from the command line while a Moxie.Build system is not otherwise already running.

 

TRON

Takes two parameters, FilePath, ForceFlush

 

ServerLog

Takes one parameter, ServerLogText

 

SaveFile

Takes two parameters, FileName, FileData

 

Thread

Takes a variable number of parameters

 

TopWith

Takes one parameter, FieldBase

 

TopField

Takes one parameter, FieldName

 

FailIfRecError

Has no parameters

 

Export and Import of Database Schema

ExportSchema and ImportSchema are BuiltIn procedures that are available for use with source control systems.

 

[Temp] Field

Parameter is a single new field name or a space separated list of new field names.

 

LoadPipeFile

Takes two parameters, FileName, bHasHeader

 

Message Handler

A Message Handler is only ever called by the Database on a Database Event. These Event Messages allow a Developer to intercept operations taking place on a per-record level and implement Event based business logic.

 

Table Action

Table Actions are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As an Action, the Procedure is expected to perform some sort of task, such as an automated set of updates to the Database Table.

 

[SearchSort]

Parameter is a space separated list of field names to have the display table sorted by when displaying search results in the Admin interface.

 

Learn More about Frontend Development

Prerequisites: This tutorial assumes that you have already set up a Category and Procedure if necessary. This page covers some of the basics that are involved in Front End development using the MOX language.

 

 

 

[!] Limited Selection List (DB Field Attribute)

Parameter is a comma separated list (using CSV rules and not in quotes) of the options made available to the user which are enforced on save.

 

MOX Coding and Programing Language Syntax Documentation

The MOX coding and programming language pays heritage to BASIC, but has been crafted for the specific type of work and environment that is demanded of Moxie.Build.

 

Call

Takes a variable number of parameters

 

AppendFile

Takes two parameters, FileName, FileData

 

EmailErr

Takes two parameters, SubjectPrefix, EmailBody

 

ETableReply

Takes 2 parameters, Result, Status

 

Error

Takes one parameter, the text of the error to throw.

 

Table Report

Table Reports are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As a Report, the Procedure is expected to produce output to be displayed to the user.

 

Public Method

A Public Method may be called from any other Procedure, by the Default plug-in as part of the CMS.

 

PaaS Method

A PaaS Method may be called by any other Moxie system. In order to call a PaaS Method from MOX, the PaaS statement is used.

 

Record Action

Record Actions are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As an Action, the Procedure is expected to perform some sort of task, such as an automated set of updates to the Database Record.

 

Remote Method

A Remote Method may be called by any other Moxie system. It can be used to divide up a large system among a number of backend servers, or as a public API for 3rd parties. In order to call a Remote Method from MOX, the Remote statement is used.

 

Record Report

Record Reports are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As a Report, the Procedure is expected to produce output to be displayed to the user.

 

JsonEncode$

Has two parameters: Source, Options

 

JsonDecode$

Has two parameters: Source, Options

 

JsonStream$

Has one parameter, Options

 

Len%

Takes one parameter, a Source value

 

Lang$

Takes one parameter, Source

 

Json$

Has two parameters: Source, Name

 

Greg$

Takes one parameter, a gregorian number

 

Greg%

Takes one parameter, a date of the form yyyy-mm-dd

 

HttpHeader$

Has one parameter

 

HttpSoap$

Takes 8 parameters, ServerName, Port, bSecure, Path, ExtraHttpHeaders, Envelope, ExtraBody, xml

 

HttpHeaders$

Has no parameters

 

TimeAdd$

Takes two parameters, Source, Value

 

TabStream$

Takes one parameter, bNoHeaders

 

TimeDif$

Takes two parameters, Source, Value

 

TimeSub$

Takes two parameters, Source, Value

 

TimeRfc3339$

Takes two parameters, Source, Options

 

Shell$

Takes two parameters Command, Options

 

LongDate$

Takes one parameter, a Date value

 

LoadFile$

Takes three parameters, FilePath, Start, Len

 

NulStream$

Takes one parameter, bNoHeader

 

RawStream$

Has no parameters

 

Parse$

Takes four parameters, Source, bAny, Search, Item

 

GeoDistance$

Takes five parameters, Lat1, Long1, Lat2, Long2, Options

 

[TQRecCount]

Has no parameters

 

[TQName]

Has no parameters

 

[TQResult]

Takes either one parameter, ResultValue, or no parameters

 

[WQFldCount]

Takes no parameters

 

[WQFieldList]

Has no parameters

 

[TQMessage]

Takes one parameter, Message, or no parameters

 

[CountIf]

Takes one parameter, TestCondition

 

[AnyRecError]

Takes no parameters.

 

[Me]

Takes no parameters

 

[TQFldCount]

Takes no parameters

 

[TQFieldList]

Takes no parameters

 

Ctid$

Has one parameter.

 

CsvStream$

Takes one parameter bNoHeaders and returns the result to an assigned variable

 

DateTime$

Takes one parameter, Source

 

FieldStream$

Takes two parameter: FieldName, Delimiter

 

FieldDef$

Takes one parameter, FieldName

 

CFApi$

Takes three parameters Method, URL, Body

 

[WQName]

Has no parameters

 

[WQMessage]

Takes one parameter, Message, or no parameters

 

[WQRecCount]

Has no parameters

 

ApplyLang$

Takes one parameter

 

[WQResult]

Takes either one parameter, ResultValue, or no parameters