Modifying a virtual table
Use the POST update API command to change the value of a virtual table.
Command
POST update
Parameters
- projectContent
- A parameter that indicates there is an associated XML document that describes the data to create or update within the project.
Available HTTP methods
HTTP method | URI pattern | Data format | Success codes | Error codes |
---|---|---|---|---|
POST | update | XML | 200 | 400 (bad request) or 500 (server error) |
Example HTTP request
https://ServerName:9443/ibm/iis/ia/api/update
Example XML string of the classical virtual table
The operator attribute, Gender in the following classical virtual table is dropped and the where condition is changed.<?xml version="1.0" encoding="UTF-8"?>
<iaapi:Project xmlns:iaapi="http://www.ibm.com/investigate/api/iaapi" name="ProjectName">
<DataSources>
<DataSource name="SOURCE">
<Schema name="BANK">
<VirtualTable name="VIRTUAL_TABLE" baseTable="CLIENTS">
<WhereCondition>GENDER='F'</WhereCondition>
<Column name="LASTNAME"/>
<Column name="FIRSTNAME"/>
<Column name="DATEOFBIRTH"/>
<Column name="GROSSSALES"/>
</VirtualTable>
</Schema>
</DataSource>
</DataSources>
</iaapi:Project>
Example XML string of the SQL virtual table
The operator attribute, Age in the following SQL virtual table is dropped and the select statement is changed.<?xml version="1.0" encoding="UTF-8"?>
<iaapi:Project xmlns:iaapi="http://www.ibm.com/investigate/api/iaapi" name="ProjectName">
<DataSources>
<DataSource name="SOURCE">
<Schema name="BANK">
<VirtualTable name="SQL_VIRTUAL_TABLE">
<SelectStatement>SELECT name, gender FROM BANK.BANK_CLIENTS WHERE gender='M'</SelectStatement>
<Column name="name" type="string" length="64"/>
<Column name="gender" type="string" length="2"/>
</VirtualTable>
</Schema>
</DataSource>
</DataSources>
</iaapi:Project>