Using the Example Databases
DatabaseLink contains a number of example databases (many use HSQLDB). These allow you to try examples in the documentation and learn the details of working with databases in Mathematica. The examples are configured to run in $UserBaseDirectory/DatabaseResources/Examples (they cannot reside inside the main Mathematica installation directory). To run these examples you will need to install them. You can do this by copying the files or by running the command
from the
package. This function will install the examples (if necessary) or restore them to their original state.
The following shows the location of the database examples on this computer.
| In[1]:= |
| Out[1]= |
| <<DatabaseLink`DatabaseExamples` | load the database examples package |
| DatabaseExamplesBuild[" "] | install and restore the database examples |
You must run
the first time you want to use the documentation, and after you have been working with the example databases and want to restore them to their original state.
| In[2]:= |
Then the examples are installed, if necessary, or restored to their original state.
| In[3]:= |
If you want to install the examples by hand, copy the Examples directory from inside the DatabaseLink installation directory (typically this is $InstallationDirectory/SystemFiles/Links/DatabaseLink) to $UserBaseDirectory/DatabaseResources.
