# Access Priority via ODBC
The Priority ODBC driver allows 3rd party applications to access data on the Priority server using SQL statements.
This is "faux" ODBC built on top of Priority forms (which are accessible via the web api). It has harsh limitations on the SQL that can be used
More info: https://prioritysoftware.github.io/odbc
## Setup
### Install the driver
1. Download latest version of driver from: https://cdn.priority-software.com/upgrades/var/odbc/22.1/priodbc.zip
2. Extract it.
3. Run `cmd` as admin.
4. cd to the directory where the driver was extracted to.
3. Run `install.bat`
4. Verify. In windows search box type `ODBC Data Sources (64-bit)`, then click *Drivers* tab. You should see *Priority ODBC Unicode Driver* listed.
### Add User Data Source Name (DSN)
This step should be repeated for each data source.
1. In the ODBC Data Sources (64-bit) utility, switch to the User DSN tab.
2. Click Add.
3. Choose Priority ODBC Unicode Driver and click Finish.
4. Configure the connection properties (examples are for the data for the Priority demo server)
- Data Source Name: a unique name for the data source that will be used later (e.g. `Priority Demo`)
- Description (optional): a description of the data source (e.g. `Priority ODBC demo server`)
- Server: address of the ODBC service on the application server (e.g. `https://www.eshbelsaas.com/ui/mob/odbc/`)
- Tabula.ini: name of configuration file in Priority server (e.g`tabmob.ini`)
- Language: 1 for Hebrew, 3 for English
- User: Priority User Name (e.g. `apidemo`)
- Password: Priority Password (e.g. `123`)
- Database: Priority database: (e.g. `usdemo`)
5. Click `Test`. You should get a message box saying "Connection Successful"
## Connect
### Using Excel
1) Data > Get Data > From Other Sources > From ODBC
2) Data Source Name (DSN) select any of those defined in steps above (e.g. `Priority Demo`)
3) If prompted, enter user name and password (e.g `apidemo` and `123`)
This will allow you to see available tables and preview available columns in order to formulate the required SQL statements.
Note that Priority requires explicit columns names for `Select` statements. You **can not** use `SELECT *`
Work with Power Query Editor
### Using Contiki
#### Configure an Import in Contiki
1. Step 1: Create a new Global name
2. Step 2: Create an import name and select source `ODBC`
3. Step 3: In the "Connection box" enter `DSN=` followed by the name of any of those defined in steps above (e.g `DSN=Priority Demo`)
4. Click
5. Box enter the SQL you want to run (e.g: `SELECT PARTNAME, TYPE FROM PART;`)
5. Click `Test`.