Developing Apama Applications > Developing Apama Applications in Event Modeler > Using Standard Blocks > Database functionality—storage and retrieval
Database functionality—storage and retrieval
The Database blocks let you store rows in a database and send queries to the database to retrieve a set of rows. They take parameters that let you specify a database name, a table name, a user name and password, and a service identifier. Note that any password given in the scenario or through the dashboard will be visible on screen.
The ADBC Storage block takes a list of fields and a list of values as parameters. The block places the values into their corresponding entry into the list of fields. Alternatively, the storage block takes a storage query or statement.
The ADBC Retrieval block takes a query string as a parameter. If you specify a query template, there is a parameter for specifying the query template parameters.
The format for a complete query string is service specific, typically SQL or an SQL-like language. When you specify a complete query, the block ignores the parameters that list fields, values, or a where clause.
The retrieval block return a number of outputs, one for each field/value pair for each row that matched the query. The scenario needs to call the next operation to retrieve the next field/value pair. The row number indicates when a field/value pair belongs to a different row. The row number counts from 1 upwards.
Copyright © 2013 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or Terracotta Inc., San Francisco, CA, USA, and/or Software AG (Canada) Inc., Cambridge, Ontario, Canada, and/or, Software AG (UK) Ltd., Derby, United Kingdom, and/or Software A.G. (Israel) Ltd., Or-Yehuda, Israel and/or their licensors.