Skip to content

Refreshing data#

An integrated table is not updated by itself: when the source file changes, you have to load it again. The Refresh data wizard uploads the new file and loads it into the integrated tables with the method you choose: replace everything, add what is new, update what is already there or delete. The load does not change the metadata: the documents that use the table stay the same and, when they are recalculated, they show the new data.

Before you start#

  • You need Workbook administration and Access to Empowerment Center, and the access privilege of the table you are going to refresh.
  • The new file must have the same headers as the one that was integrated: the columns are matched by their name, not by their position.
  • For any method other than Total, the table needs a primary key and the file must include its columns.
  • The tables integrated in Empowerment Center 7 are not refreshed from here (see Viewing and deleting external data).

Loading a file#

  1. On the External data page, click Refresh data… (in the header or in the panel of a table). If the file is already in the pending uploads, click Refresh… in its row.
  2. Upload the file with Upload and analyze, as when integrating (see Preparing the file).
  3. In the Destinations and load step, leave Standard load process chosen.
  4. For each table of the file you want to load:
    1. Check its checkbox.
    2. Choose the Destination: the integrated table it is loaded into. ECenter proposes the one that best matches its columns.
    3. Choose the Load method (below). Under the selector it explains what it does.
  5. Check the line that appears under each table: “5 columns are loaded; … are missing; … are ignored”.
  6. Click Process.

When it finishes, the wizard says “The process finished successfully” and, for each destination, what happened: “Campaña de fidelización: Partial update and insert · 5 inserted, 5 updated, 0 deleted”. Click Back to External data. The panel of the table shows the load in Last load.

The “Destinations and load” step with the October CSV loaded into “Campaña de fidelización” with “Partial update and insert”The “Destinations and load” step with the October CSV loaded into “Campaña de fidelización” with “Partial update and insert”
The “Destinations and load” step with the October CSV loaded into “Campaña de fidelización” with “Partial update and insert”

The load methods#

Method What it does Needs a key
Total Deletes all the records of the destination and then inserts those of the file. No
Partial update Looks up each row of the file by its key in the destination and updates the ones it finds. Those that are not there are not inserted. Yes
Partial insert Inserts the rows of the file whose key is not in the destination. It does not touch the ones already there. Yes
Partial delete Deletes from the destination the rows whose key comes in the file. Yes
Partial update and insert Updates the ones it finds and inserts the ones it does not. Yes

For example, to add the October participants to the campaign and correct the points of those who were already there, use Partial update and insert with a file that only contains those participants. To replace the whole table with the new version of the file, use Total.

How the columns are matched#

  • The columns of the file are matched with those of the destination by their name (the one that comes from the header, see Preparing the file).
  • A column of the destination that does not come in the file is left empty in the inserted rows and untouched in the updated ones.
  • A column of the file that is not in the destination is ignored, and the result warns you: “'…' no tiene la columna Observación de '…': no se carga” ('…' does not have the column Observación of '…': it is not loaded). To add a new column to the table, delete the table and integrate it again.
  • The columns of the key must come in the file.
  • Each value is converted to the type of the destination column. If a value cannot be converted (a text where a number goes), the load fails and nothing is loaded.

All or nothing#

All the loads of the same process go together: if one fails, none is loaded and the destination stays as it was. While loading, the destination tables are locked, and the documents that query them may have to wait for it to finish.

Before loading, ECenter checks that the file does not repeat keys or bring empty keys. If it does, it loads nothing and says so.

Several tables into the same destination#

You can load two tables of the file into the same destination with partial methods (for example, insert the January additions and the February ones). What you cannot do is combine a Total load with another one into the same destination: the total one would delete what the others load. The wizard says so before processing: ““…” receives several tables from the file and the full load of one would delete what the others load: choose another destination or a partial method”.

Calling a stored procedure#

Some loads are too complex for the standard methods: distributing the data among several tables, validating them, transforming them. For them, the metadata administrator can register stored procedures of the database that can be called when refreshing.

  1. In the Destinations and load step, choose Stored procedure. If none is registered for the connection, the option is disabled and the wizard says so.
  2. Choose the Procedure.
  3. In Tables in the file, check the tables that are passed to it.
  4. Click Process.

The procedure receives a single parameter: the names of the chosen tables of the file, in full and separated by commas. What it does with them is up to the procedure. When it finishes, the wizard says “The procedure … has been run”. As ECenter does not know which tables the procedure has written to, the Last load of the integrated tables does not change.

Registering the allowed procedures#

Only with Metadata administration:

  1. On the External data page, choose ⋯ › Allowed procedures….
  2. In Procedures, one per line, type the name of each procedure as schema.name.
  3. Click Save.

The procedures run with the user of the connection, so only register those designed to receive these tables.

Leaving without loading#

Cancel, or leaving the page before processing, asks “Leave without loading the file?”. The file stays in the pending uploads until it expires, and you can continue with it with Refresh… in its row.

See also#