Close import context

<< Click to Display Table of Contents >>

Navigation:  Technical documentation > Importing data > Import contexts >

Close import context

Previous pageReturn to chapter overviewNext page

After you have successfully written data to the FastTrak database, you may choose to close the import context.


EXEC CloseImportContext 14,'2008-08-15 12:03:44'


The call to CloseImportContext takes two parameters, the first is a ContextId returned by OpenImportContext, and the second is the date of the last data written.  This date will be returned in the next call to OpenImportContext as LastUpdated.  The second parameter is the datetime as seen from the client.  This is relevant because the client and the server may run in different time zones.


There is no result set from this procedure.  There will be an exception thrown if the closure was not succesful.  This is very unlikely, but could happen if the date was in an unrecognized format, or if the user does not have sufficient rights to execute the procedure.l


Leaving an import context open

If you leave an import context open, the LastUpdate will not be updated, which means that the client will probably have to write more data next time.  This doesn't really do any harm, it just means redundant work in the next update.