Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The question mark ? is a placeholder for the value within the prepared statement. The value will be inserted by the JDBC driver when the prepared statement is being executed. MIB Explorer sets the value for the statement by replacing the @VALUEID reference with the ? in the statement and setting the statements first parameter value to the value of ID (for example 2). |

Tag

...

Description

...

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="15ad730c14fdea2a-5bfdccd0-4d1d4e6d-90d583df-0328feb90cf8abfd4c644f98"><ac:plain-text-body><![CDATA[

@VALUE[<param>]

Replace the tag by
]]></ac:plain-text-body></ac:structured-macro>
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="4771403c-7fa9-4022-bf39-a83ece384cd2"><ac:plain-text-body><![CDATA[ Example:? in the statement and set the value of the prepared parameter to the value of the MIB Explorer variable with name <param>.

Code Block
SELECT ID FROM MXP.MXP_MONITOR WHERE NAME = @VALUE\[NAME\]

will be rendered toSELECT ID FROM to

Code Block
SELECT ID FROM MXP.MXP_MONITOR WHERE NAME = ?

where ? is assigned with the value of the MIB Explorer variable NAME when the statement is being executed. ]]></ac:plain-text-body></ac:structured-macro>

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="70096c500d246245-241b2aa1-4faf44d1-b36a8cba-09fdabf150479d98ed095d1b"><ac:plain-text-body><![CDATA[

@INSERT[<param>]

Replace the tag by the value of MIB Explorer variable with name <param>
]]></ac:plain-text-body></ac:structured-macro>
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="67b16903-712e-47d1-892c-b60e04291466"><ac:plain-text-body><![CDATA[Example:<param>. SELECT ID FROM Example:

Code Block
SELECT ID FROM MXP.MXP_MONITOR WHERE NAME = '@INSERT\[NAME\]'

will be rendered toSELECT ID FROM to

Code Block
SELECT ID FROM MXP.MXP_MONITOR WHERE NAME = 'MyMonitor'

if the variableNAME variable NAME has the string value MyMonitor.

]]></ac:plain-text-body></ac:structured-macro>

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="fdcfd70c8e66debd-75db273d-46a24c00-8a90818e-c0bfb12209320cec0fbb8d13"><ac:plain-text-body><![CDATA[

@USE[<statementName>]

Replace the tag with the rendered content of the statement with name
]]></ac:plain-text-body></ac:structured-macro>
Example:<statementName> of the same context. <statement name="select.id">
SELECT ID
</statement>
<statement name="select.monitor.id.by.name">
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="bca1922df9846e61-979c3c04-46b641fd-95b0a2e7-f3667e5298f8e1d2fddf8194"><ac:plain-text-body><![CDATA[@USE[select.id] FROM MXP.MXP_MONITOR WHERE NAME = @VALUE[NAME]
]]></ac:plain-text-body></ac:structured-macro>
</statement>will be rendered toSELECT ID FROM MXP.MXP_MONITOR WHERE NAME = 'MyMonitor'if the variableNAME has the string value MyMonitor.

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="ff652acac879807b-7cdd6743-47d641b1-a10cb404-be63a87a29e1de4fc2790891"><ac:plain-text-body><![CDATA[

@IF[<stmt>,<test>,<value>..]

Replace the tag with the statement with name
]]></ac:plain-text-body></ac:structured-macro>
Example:<stmt> if the condition <test> is true for the MIB Explorer variable references <value1> through <valueN>. The supported tests are listed in table Table 16 on page 144. <statement name="monitor.dataset.by.id">
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="0e8fe1c26eb7c19f-413648e1-45544b58-a7bb9bd7-0809d98b02b9bdb44d966cc1"><ac:plain-text-body><![CDATA[SELECT * FROM MXP.MXP_MONITORDATASET WHERE MONITOR_ID = @VALUE[ID]
]]></ac:plain-text-body></ac:structured-macro>
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="6511157b11f66cac-6189e513-4d1947c7-8effbfb3-a43a55af6f81d1fba8edefa8"><ac:plain-text-body><![CDATA[@IF[and.nameOrDataType,not-null,NAME,DATATYPE]
]]></ac:plain-text-body></ac:structured-macro>
ORDER BY MONITOR_ID,DATATYPE
</statement>
<statement name="and.nameOrDataType">
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="5116039fb67e8605-ce26eb67-4854472b-8b9db7e6-9144a9d993815f61d6b60af4"><ac:plain-text-body><![CDATA[AND (NAME = @VALUE[NAME] OR DATATYPE = @VALUE[DATATYPE])
]]></ac:plain-text-body></ac:structured-macro>
</statement>will be rendered toSELECT * FROM MXP.MXP_MONITORDATASET WHERE MONITOR_ID = ? AND (NAME = ? OR DATATYPE = ?) ORDER BY MONITOR_ID,DATATYPEif the MIB Explorer variablesNAME and DATATYPE are not null.

<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="e36928fe279b6f3e-8c93241a-49e64c83-b880b0ea-770130b0e348b20ce30b2467"><ac:plain-text-body><![CDATA[

@IFELSE[<stmtTrue>, <stmtFalse>,<test>, <value>..]

Replace the tag with the statement with name
]]></ac:plain-text-body></ac:structured-macro>
Example:<stmtTrue> if the condition <test> is true for the MIB Explorer variable references <value1> through <valueN>. Otherwise, replace the tag with the statement with name <stmtFalse>. The supported tests are listed in table Table 16 on page 144. <statement name="monitor.dataset.by.id">
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="4cee06d1ba14af00-9a0ff57d-442c463f-bdde9ef3-b10723799de9cfbaf1ed048a"><ac:plain-text-body><![CDATA[SELECT * FROM MXP.MXP_MONITORDATASET WHERE MONITOR_ID = @VALUE[ID]
]]></ac:plain-text-body></ac:structured-macro>
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="c3a9dede1bedd5de-52a85199-4a3445b6-bd8daa63-fae8cdd8afbe867d7a561920"><ac:plain-text-body><![CDATA[@IFELSE[dataTypeNotNull,dataTypeNull,not-null,DATATYPE]
]]></ac:plain-text-body></ac:structured-macro>
</statement>
<statement name="dataTypeNull">
AND DATATYPE IS NULL
</statement>
<statement name="dataTypeNotNull">
AND DATATYPE IS NOT NULL
</statement>will be rendered toSELECT * FROM MXP.MXP_MONITORDATASET WHERE MONITOR_ID = ? AND DATATYPE IS NOT NULLif the MIB Explorer variablesDATATYPE is not null. Otherwise, the statement would be rendered as: SELECT * FROM MXP.MXP_MONITORDATASET WHERE MONITOR_ID = ? AND DATATYPE IS NULL