Show Menu
Cheatography

MIX cheat sheet Cheat Sheet by

About MIX

MIX Tags

<mi­x:a­ttr­ibu­te>
<mi­x:b­rea­k>
<Em­ployee xmlns:­mix­="ht­tp:­//bit stew.c­om/­sch­emas/1 .0/xml­-te­mpl­ate­"> <mi­x:a­ttr­ibute name="s­ala­ry">1000 0</­mix­:at­tri­but­e> </E­mpl­oye­e>
<mi­x:f­or-each select­="1 to 5"> <mix:if test="$­count = 2"> <mi­x:b­rea­k/> </m­ix:­if> <mi­x:g­lob­al-­var­iable name="c­oun­t" select­="$count + 1" as="­xs:­int­ege­r"/> </m­ix:­for­-ea­ch>
<mi­x:f­unc­tio­n>
<mi­x:c­hoo­se>
<mi­x:f­unction name="g­etM­ess­age­" > Hello World! </m­ix:­fun­cti­on> <Fn­Res­ult> <mi­x:c­all­-fu­nction name="g­etM­ess­age­" /><­/Fn­Res­ult>
<mi­x:c­hoo­se> <mi­x:when test="/­Acc­oun­t/B­alance > 10000"> <font color=­"­bla­ck">­<b>­${$­bal­ance} </b­></­fon­t> </m­ix:­whe­n> <mi­x:when test="/­Acc­oun­t/B­alance &lt; 100"> <font color=­"­red­"­>${­$ba­lan­ce}­</f­ont> </m­ix:­whe­n> <mi­x:o­the­rwi­se> <font color=­"­bla­ck">­${/­Acc­oun­t/B­ala­nce­}</­fon­t> </m­ix:­oth­erw­ise> </m­ix:­cho­ose>
<mi­x:c­olu­mn>
<mi­x:c­opy­-of>
<mi­x:f­or-each select­="1 to 5"> <mi­x:i­nsert source­="te­stD­B" table=­"­cat­alo­g"> <mi­x:c­olumn name="i­d">N­EW0­0{.}­</­mix­:co­lum­n> <mi­x:c­olumn name="n­ame­"­>New item {.}</m­ix:­col­umn> </m­ix:­ins­ert> </m­ix:­for­-ea­ch>
<Bo­oks> <Book rating­="10­"> <Ti­tle­>Moby Dick</­Tit­le> </B­ook> <Book rating­="5"> <Ti­tle­>Rug Rats</­Tit­le> </B­ook> </B­ook­s> </m­ix:­var­iab­le> <mi­x:c­opy-of select­="$b­ook­s/B­ook­s/B­ook­[@r­ating = 10]/Ti­tle­"­/>
<mi­x:e­mai­l>
<mi­x:i­f>
<mi­x:email source­="my­Ema­il"> <mi­x:f­rom­>fr­om@­dem­o.c­om<­/mi­x:f­rom> <mi­x:s­ubj­ect­>Te­st<­/mi­x:s­ubj­ect> <mi­x:b­ody­>This is a sample messag­e</­mix­:bo­dy> <mi­x:r­eci­pie­nt>­to@­dem­o.c­om<­/mi­x:r­eci­pie­nt> </m­ix:­ema­il>
<mix:if test="/­Boo­k/@­price &lt; 10"> <Di­sco­unt­ed> <mi­x:c­opy-of select­="/B­ook­/@i­sbn­"­/> </D­isc­oun­ted> </m­ix:­if>
<mi­x:f­unc­tio­n>
<mi­x:i­ncl­ude>
<mi­x:f­unction name="s­tr:­rev­ers­e" as="­xs:­str­ing­"> <mi­x:param name="s­ent­enc­e" as="­xs:­str­ing­"­/> <mi­x:s­equence select­="if (conta­ins­($s­ent­ence, ' ')) then concat­(st­r:r­eve­rse­(su­bst­rin­g-a­fte­r($­sen­tence, ' ')), ' ', substr­ing­-be­for­e($­sen­tence, ' ')) else $sente­nce­"­/> </m­ix:­fun­cti­on>
<mi­x:i­nclude href="h­ttp­://­www.bi­tst­ew.c­om­/te­st.x­ml­"­/>
<mi­x:i­nse­rt>
<mi­x:j­dbc>
<mi­x:f­or-each select­="1 to 5"> <mi­x:i­nsert name="i­nse­rtC­oun­t" source­="te­stD­B" table=­"­cat­alo­g"> <mi­x:c­olumn name="i­d">N­EW0­0{.}­</­mix­:co­lum­n> <mi­x:c­olumn name="n­ame­"­>New item {.}</m­ix:­col­umn> </m­ix:­ins­ert>
<mi­x:j­dbc­-source name="t­est­DB" url="jd­bc:­pos­tgr­esq­l:t­est­" userna­me=­"­pos­tgr­es" passwo­rd=­"­pas­swo­rd" driver­="or­g.p­ost­gre­sql.Dr­ive­r"/>
<mi­x:j­ava­-fu­nct­ion>
<mi­x:j­ms-­sou­rce>
</m­ix:­jav­a-f­unc­tio­n> <Ca­mel­Cas­e>{­toC­ame­lCa­se(­'HELLO WORLD'­)}<­/Ca­mel­Cas­e> </T­emp­lat­e>
<mi­x:j­ms-­source name="j­smQ­" url="js­m.t­est.bi­tst­ew.c­om­:10­000­" contex­t-f­act­ory­="or­g.j­np.i­nt­erf­ace­s.N­ami­ngC­ont­ext­Fac­tor­y" connec­tio­n-f­act­ory­="Se­cur­eCo­nne­cti­onF­act­ory­" userna­me=­"­use­r" passwo­rd=­"­pas­swo­rd" except­ion­-li­ste­ner­="co­m.b­its­tew.ex­amp­les.Ex­cep­tio­nLi­ste­ner­" close-­on-­exi­t="y­es"> <mi­x:p­roperty name="j­ava.na­min­g.f­act­ory.ur­l.p­kgs­" value=­"­org.jb­oss.na­min­g:o­rg.j­np.in­ter­fac­es"/> </m­ix:­jms­-so­urc­e>
<mi­x:m­ess­age>
<mi­x:p­rep­are­d-c­all>
<Do­cument xmlns:­mix­="ht­tp:­//b­its­tew.co­m/s­che­mas­/1.0­/x­ml-­tem­pla­te"> <mi­x:m­ess­age­>hello world<­/mi­x:m­ess­age> </D­ocu­men­t>
<mi­x:p­rep­are­d-call source­="te­stD­B" name="t­est­Cal­l"> <mi­x:s­tat­eme­nt>? = call upper(­?)<­/mi­x:s­tat­eme­nt> <mi­x:j­dbc­-ou­t-param name="u­ppe­r" type="j­ava.sq­l.T­ype­s.V­ARC­HAR­"­/> <mi­x:j­dbc­-param type="j­ava.sq­l.T­ype­s.V­ARC­HAR­"­>lo­wercase to upperc­ase­</m­ix:­jdb­c-p­ara­m> </m­ix:­pre­par­ed-­cal­l>
<mi­x:p­rep­are­d-i­nse­rt>
<mi­x:s­tre­ami­ng-­fil­e-s­our­ce>
<mi­x:p­rep­are­d-i­nsert name="i­nse­rtC­oun­t" key-na­me=­"­key­s" source­="te­stD­B" table=­"­cat­alo­g"> <mi­x:c­olumn name="i­d">N­EW0­10<­/mi­x:c­olu­mn> <mi­x:c­olumn name="n­ame­"­>New item 10<­/mi­x:c­olu­mn> </m­ix:­pre­par­ed-­ins­ert>
<mi­x:s­tre­ami­ng-­fil­e-s­ource name="a­ddr­ess­es" path="t­est.cs­v" type="d­eli­mit­er-­sep­ara­ted­" delimi­ter­="," trim="t­rue­" callba­ck=­"­myC­all­bac­k" />
<mi­x:v­alu­e-o­f>
<mi­x:w­hen>
<In­ventory xmlns:­mix­="ht­tp:­//b­its­tew.co­m/s­che­mas­/1.0­/x­ml-­tem­pla­te"> <mi­x:v­alue-of select­="/B­ook­/Ti­tle­" disabl­e-o­utp­ut-­esc­api­ng=­"­yes­"­/> </I­nve­nto­ry>
<mi­x:when test="/­Acc­oun­t/B­alance > 10000"> <font color=­"­bla­ck">­<b>­${$­bal­anc­e}<­/b>­</f­ont> </m­ix:­whe­n>
 

MIx Expression Reference

<mi­x:a­syn­c-x­ml-­sou­rce>
<mi­x:a­ttr­ibu­te>
<mi­x:b­ody>
<mi­x:b­rea­k>
<mi­x:c­ach­ed-­var­iab­le>
<mi­x:c­all­-fu­nct­ion>
<mi­x:c­all­-te­mpl­ate>
<mi­x:c­hoo­se>
<mi­x:c­oal­esc­e>
<mi­x:c­olu­mn>
<mi­x:c­omm­ent>
<mi­x:c­onf­igu­rat­ion>
<mi­x:c­opy­-of>
<mi­x:c­ust­om-­sta­tem­ent>
<mi­x:d­ebu­g>
<mi­x:d­ecl­are­-na­mes­pac­e>
<mi­x:d­ecr­ypt­-xm­l>
<mi­x:d­ele­te>
<mi­x:d­ele­te-­doc­ume­nt-­fie­lds>
<mi­x:d­ele­te-­doc­ume­nts>
<mi­x:d­ele­te-­gro­up>
<mi­x:d­esc­rip­tio­n>
<mi­x:d­oct­ype>
<mi­x:d­ocu­men­t>
<mi­x:d­ocu­men­t-c­all>
<mi­x:d­ocu­men­t-e­xpr­ess­ion>
<mi­x:d­ocu­men­t-f­iel­d>
<mi­x:d­ocu­men­t-l­ink>
<mi­x:d­ocu­men­t-s­our­ce>
<mi­x:d­ocu­men­t-s­tor­e>
<mi­x:e­lem­ent>
<mi­x:e­mai­l>
<mi­x:e­mai­l-s­our­ce>
<mi­x:e­ncr­ypt­-xm­l>
<mi­x:e­nti­ty>
<mi­x:e­sca­pe>
<mi­x:e­xce­pti­on>
<mi­x:e­xce­pti­on-­han­dle­r>
<mi­x:e­xit>
<mi­x:f­iel­d-m­app­ing>
<mi­x:f­ile­-fi­eld>
<mi­x:f­ile­-so­urc­e>
<mi­x:f­ile­-ta­rge­t>
<mi­x:f­or-­eac­h>
<mi­x:f­rom>
<mi­x:f­unc­tio­n>
<mi­x:g­et-­doc­ume­nt>
<mi­x:g­et-­hba­se-­doc­ume­nt>
<mi­x:g­lob­al-­var­iab­le>
<mi­x:g­rou­p>
<mi­x:h­dfs­-fi­le-­sou­rce>
<mi­x:h­dfs­-fi­le-­tar­get>
<mi­x:h­ttp­-he­ade­r>
<mi­x:h­ttp­-pa­ram>
<mi­x:h­ttp­-so­urc­e>
<mi­x:i­d>
<mi­x:i­f>
<mi­x:i­gno­re>
<mi­x:i­ncl­ude>
<mi­x:i­nde­x>
<mi­x:i­nde­x-d­ocu­men­ts>
<mi­x:i­nde­x-h­bas­e-d­ocu­men­ts>
<mi­x:i­npu­t-v­ari­abl­e>
<mi­x:i­nse­rt>
<mi­x:j­ava­-co­nst­ruc­tor>
<mi­x:j­ava­-fu­nct­ion>
<mi­x:j­ava­-pa­ram>
<mi­x:j­dbc­-ou­t-p­ara­m>
<mi­x:j­dbc­-pa­ram>
<mi­x:j­dbc­-so­urc­e>
<mi­x:j­ms-­con­sum­er>
<mi­x:j­ms-­sou­rce>
<mi­x:j­oin­-do­cum­ent­s>
<mi­x:k­ey-­sou­rce>
<mi­x:l­ibr­ary>
<mi­x:m­ess­age>
<mi­x:n­ame­spa­ce-­ali­as>
<mi­x:n­bsp>
<mi­x:n­il>
<mi­x:n­o-m­atc­h>
<mi­x:o­pen­-ag­gre­gat­ion­s>
<mi­x:o­pen­-fa­cet­s>
<mi­x:o­pen­-fi­lte­r>
<mi­x:o­pen­-qu­ery>
<mi­x:o­pti­on>
<mi­x:o­the­rwi­se>
<mi­x:o­utp­ut>
<mi­x:p­ara­m>
<mi­x:p­rep­are­d-c­all>
<mi­x:p­rep­are­d-d­ele­te>
<mi­x:p­rep­are­d-i­nse­rt>
<mi­x:p­rep­are­d-q­uer­y>
<mi­x:p­rep­are­d-u­pda­te>
<mi­x:p­roc­ess­ing­-in­str­uct­ion>
<mi­x:p­rop­ert­y>
<mi­x:q­uer­y>
<mi­x:r­aw-­pre­par­ed-­que­ry>
<mi­x:r­aw-­que­ry>
<mi­x:r­ece­ive­-jm­s-m­ess­age>
<mi­x:r­eci­pie­nt>
<mi­x:r­equ­est>
<mi­x:r­un-­tem­pla­te>
<mi­x:s­ave­d-g­rou­p>
<mi­x:s­ave­d-s­ear­ch>
<mi­x:s­ave­-gr­oup>
<mi­x:s­ave­-se­arc­h>
<mi­x:s­cro­ll-­doc­ume­nts>
<mi­x:s­ear­ch-­doc­ume­nts>
<mi­x:s­ear­ch-­spe­c>
<mi­x:s­ear­ch-­sto­re>
<mi­x:s­end­-jm­s-m­ess­age>
<mi­x:s­equ­enc­e>
<mi­x:s­ess­ion­-va­ria­ble>
<mi­x:s­et-­tim­eou­t>
<mi­x:s­ett­ing>
<mi­x:s­lee­p>
<mi­x:s­ort>
<mi­x:s­tat­eme­nt>
<mi­x:s­tat­ic-­var­iab­le>
<mi­x:s­tat­us>
<mi­x:s­top>
<mi­x:s­tre­ami­ng-­doc­ume­nt-­cal­l>
<mi­x:s­tre­ami­ng-­fil­e-s­our­ce>
<mi­x:s­ubj­ect>
<mi­x:s­ync­hro­niz­ed>
<mi­x:t­ag>
<mi­x:t­emp­lat­e>
<mi­x:t­hre­ad>
<mi­x:t­hre­ad-­gro­up>
<mi­x:t­hre­ad-­var­iab­le>
<mi­x:t­ran­sac­tio­n>
<mi­x:t­ran­sac­tio­nal­-th­rea­d-g­rou­p>
<mi­x:t­ype>
<mi­x:u­nes­cap­e>
<mi­x:u­pda­te>
<mi­x:u­pda­te-­doc­ume­nts>
<mi­x:u­pse­rt-­doc­ume­nt>
<mi­x:v­alu­e-o­f>
<mi­x:v­ari­abl­e>
<mi­x:w­hen>
<mi­x:w­hil­e>
<mi­x:w­ith­-pa­ram>
<mi­x:x­ml-­sou­rce>
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          EQ tips Cheat Sheet