Categories

Versions

(JDBC Connectors)

Synopsis

This operator writes an ExampleSet into the specified Microsoft Access database.

Description

The Write Access operator is used for writing an ExampleSet into the specified Microsoft Access database (.mdb or .accdb extension) using the UCanAccess jdbc driver. You only need to have a basic understanding of databases in order to use this operator properly. Please go through the parameters and the attached Example Process to understand the working of this operator.

Input

  • input (Data table)

    This input port expects an ExampleSet. It is output of the Retrieve operator in the attached Example Process.

Output

  • through (Data table)

    The ExampleSet that was provided at the input port is delivered through this output port without any modifications. This is usually used to reuse the same ExampleSet in further operators of the process.

Parameters

  • database fileThis parameter specifies the path of the Access database ( i.e. the mdb or accdb file)
  • usernameThis parameter is used for specifying the username of the database (if any).
  • passwordThis parameter is used for specifying the password of the database (if any).
  • table nameThis parameter is used for specifying the name of the required table from the specified database.
  • overwrite modeThis parameter indicates if an existing table should be overwritten or the data should be appended.
  • access versionIf a new database is created this parameter specifies its format version. This parameter is not used if the database already exists.

Tutorial Processes

Writing and then reading data from an Access database

The 'Golf' data set is loaded using the Retrieve operator. The Write Access operator is used for writing this ExampleSet into the golf table of the 'golf_db.mdb' database. The database file parameter is provided with the path of the database file 'golf_db.mdb' and the name of the desired table is specified in the table name parameter ( i.e. it is set to 'golf'). A breakpoint is inserted here. No results are visible at this stage but you can see that at this point of the execution the database has been created and the golf table has been filled with the examples of the 'Golf' data set.

Now the Read Access operator is used for reading the golf table from the 'golf_db.mdb' database. The database file parameter is provided with the path of the database file 'golf_db.mdb'. The define query parameter is set to 'table name'. The table name parameter is set to 'golf' which is the name of the required table. Continue the process, you will see the entire golf table in the Results Workspace. The define query parameter is set to 'table name' if you want to read an entire table from the database. You can also read a selected portion of the database by using queries. Set the define query parameter to 'query' and specify a query in the query parameter.