Establishing a Connection
Enabling SSIS in Visual Studio 2022
If you're using Visual Studio 2022, you will need to install the SQL Server Integration Services Projects extension to use SSIS.
- Navigate to Extensions > Manage Extensions.
- In the Manage Extensions window's search box, search for "SQL Server Integration Services Projects 2022" and select the extension in the list.
- Click Download.
- Close Visual Studio and run the downloaded Microsoft.DataTools.IntegrationServices.exe installer. Proceed through the installer with default settings.
- Open Visual Studio. There should now be an "Integration Services Project" project template available.
Adding the Odoo Connection Manager
Create a new connection manager as follows:
- Create a Visual Studio project with the "Integration Services Project" template.
- In the project, right-click within the Connection Managers window and select New Connection from the menu.
- In the Description column, select CData Odoo Connection Manager and click Add...
- Configure the component as described in the next section.
Alternatively, if you have an existing project and CData Odoo Source or CData Odoo Destination:
- Right-click your CData Odoo source or destination component in your data flow
- Select Edit... to open an editor window.
- Click the New... button next to the Connection manager: dropdown selector to create a connection manager.
- Configure the component as described in the next section.
Connecting to Odoo
To connect, set the Url to a valid Odoo site, User and APIToken to the connection details of the user you are connecting with, and Database to the Odoo database.If you are not using API tokens (they are only supported in Odoo 14 and above), you can also provide the password in the APIToken field.
Access Rights
In order for the component to determine what models you can access in Odoo, the user you connect with must have permissions to read from "ir.model.access" (an internal Odoo model that governs access rights). Normally this is reserved for administrators, but it can be granted to any user by creating a service group:- As an administrator, open the Odoo settings page and enable "developer mode". If this is not available you may need to login as the superuser instead.
- Open the Groups page (under the Users dropdown) and create a new group
- Set the Application to "Administration" and the name to "Service Access"
- Add any users who need service access in the Users tab
- In the Access Rights tab, add an entry for the "ir.model.access" object (it may be called "Model Access"), check Read Access, and give it the name "Inspect Models"
- Save the group
If making this change is not possible, then you should set the CheckPermissions option to false. That will list all models in Odoo as tables, regardless of what permissions your user actually has for those models.