Forum Discussion

EBradley's avatar
EBradley
New Member
1 year ago
Solved

DataSource.Error - Value Cannot be Null

Hi there! I'm sourcing data from an OLE DB, and I'm getting an error when accessing one of the tables. I've seen a few different posts about similar errors, but nothing about a parameter called "pUnk". I can access the other tables just fine. For context, here is the full error code:

 

DataSource.Error: An error happened while reading data from the provider: 'Value cannot be null.
Parameter name: pUnk'
Details:
DataSourceKind=OleDb
DataSourcePath=mode=Read;provider=IhOLEDB.iHistorian.1

  • Thank you for the reply! It ended up being on the Historian end where the parameter wasn't getting returned. There's a query limit that needs to be adjusted, so once I upped that value, data started coming through.

6 Replies

  • v-kpoloju-msft's avatar
    v-kpoloju-msft
    Community Support

    Hi EBradley,
    Thank you for reaching out to the Microsoft fabric community forum. After reviewing the details you provided, I have identified few workarounds that may help resolve the issue. Please follow these steps:

     

    The error "Value cannot be null. Parameter name: pUnk" in Power BI when using OLE DB as a data source usually indicates an issue with the OLE DB provider or the connection setup.

     

    Please ensure that the GE Historian OLE DB provider (if using GE iHistorian) is correctly installed. Reinstall or update the OLE DB provider to match your system architecture (32-bit vs. 64-bit). Verify that your connection string includes the required parameters, such as Data Source, Initial Catalog, User ID, and Password. Consider using the Microsoft OLE DB Driver for SQL Server instead of the Historian-specific provider.

     

    Test the connection in Excel or another tool to verify access. Ensure that the account has read permissions for the Historian database. Try using ODBC instead of OLE DB, or, if possible, retrieve the data through an SQL Server connection. Refresh the dataset and check for errors in Power Query steps. Simplify the query and manually add parameters if necessary.

    If the issue persists, please provide your connection string and error details for further troubleshooting.


    Refer to the below following link for better understanding:
    OLE DB Power Query Data Connector - Power Query | Microsoft Learn

    I hope this could resolve your issue, if you need any further assistance, feel free to reach out.
    If this post helps, then please give us ‘Kudos’ and consider Accept it as a solution to help the other members find it more quickly.


    Thank you for using Microsoft Community Forum.

  • Thank you for the reply! It ended up being on the Historian end where the parameter wasn't getting returned. There's a query limit that needs to be adjusted, so once I upped that value, data started coming through.

    • v-kpoloju-msft's avatar
      v-kpoloju-msft
      Community Support

      Hi EBradley,

       

      After reviewing the details you provided, I have identified few alternative workarounds that may help resolve the issue. Please follow these steps:

      If the query limit change was temporary, verify if it resets periodically. If necessary, collaborate with your Historian admin to implement a permanent change. To avoid frequently hitting query limits, consider:

      • Filtering data at the source (e.g., limiting to a specific time range).
      • Selecting only the necessary columns and using indexed fields for efficient querying.

      If data retrieval remains slow or inconsistent: Ensure the OLE DB provider has logging enabled to track query execution. Monitor system performance during data pulls to identify bottlenecks. To prevent future query limit issues, set up alerts in Historian to notify when thresholds are reached.


      If the issue persists, further troubleshooting should focus on the following steps: Testing different connection methods (OLE DB vs. ODBC vs. REST API, if available). Checking for additional limits or constraints in the Historian system (time-based, row count, user permissions).

      I hope this could resolve your issue, if you need any further assistance, feel free to reach out. If this post helps, then please give us ‘Kudos’ and consider Accept it as a solution to help the other members find it more quickly.

      Thank you for using Microsoft Community Forum.

      • v-kpoloju-msft's avatar
        v-kpoloju-msft
        Community Support

        Hi EBradley,

         

        May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

         

        Thank you.