Postgres Connection

4 posts, 0 answers
  1. Bernd
    Bernd avatar
    1 posts
    Member since:
    Mar 2018

    Posted 29 Mar 2018 Link to this post

     

    Hello,

    I try to connect to a prostgres Database with Report Designer.

    Connection is successful by connecting via odbc data source. But i fails when i`m using an connection string.

    I followed  this example:

    https://www.telerik.com/support/kb/reporting/accessing-and-managing-data/details/how-to-register-sqldatasource-data-providers-without-driver-installation

    I want to register the npgsql.dll directly in cofig file.

    Now, when i select SQL Data Source in Designer _> Build new Data connection -> Data provider (I can choose: Npgsql Data Provider) -> and type in connection string (Server=localhost; Port=5432; Database=DbName; User ID=demo; Password=demo;) 

    ERROR: Can not find registered .Net Framework-Data provider  

    Npgsql.dll and his dependencies are present in separate bin folder in AppRoot-folder.

    Any suggestions?

    Best regards,

    Bernd

     

     

     

  2. Silviya
    Admin
    Silviya avatar
    414 posts

    Posted 03 Apr 2018 Link to this post

    Hi Bernd,

    We provided the answers to your questions and the possible workarounds in the support ticket you opened for the same issue (ID #1160165).

    But since there is no sensitive information in your support thread, it is not an issue to share the original answer:

    "We tested locally to configure the Standalone Designer config file and everything seems to work as expected. However, we tested with version 3.2.1.0 of Npgsql.dll. We are not sure of the version that you are using, so please elaborate more or send us the designer's exe.config file to check and test once again.

    It would be necessary to register the Npgsql.dll assembly in the StandaloneDesigner config file with the corresponding version:
    <dependentAssembly>
            <assemblyIdentity name="Npgsql" version="3.2.1.0" culture="neutral" publicKeyToken="5d8b90d52f46fda7"/>
    </dependentAssembly>

    And also while registering the Npgsql.dll assembly:
    <add name="Npgsql" version="3.2.1.0" culture="neutral" publicKeyToken="5d8b90d52f46fda7"/>

    In case the used version is different and it causes errors, it might be because of the data provider for Postgresql Server's new update. Please revert to the stable one (3.2.1.0) to configure Npgsql for now."

    Regards,
    Silviya
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. John
    John avatar
    3 posts
    Member since:
    Feb 2019

    Posted 07 Nov in reply to Silviya Link to this post

    i'm evaluating Telerik Reporting and would like to configure the Standalone Report Designer to use Postgresql as a Data Source.

    the attached config files dont seem to work, but i'm not sure what's wrong with what i've done.

     

    i'm using Postgresql 12 with Npgsql 4.1.1 as the driver in a 64bit Windows 10 Pro desktop machine.

    i've done:

    nuget install Npgsql -Version 4.1.1

    and put all the required dlls in same folder as Telerik.ReportDesigner.exe in C:\Progress\Telerik Reporting R3 2019\Report Designer

    and my config file(s) is as follow (the x86 is same as the 64bit file)

     

    <?xml version ="1.0"?>
    <configuration>
    <configSections>
    <section
    name="Telerik.Reporting"
    type="Telerik.Reporting.Configuration.ReportingConfigurationSection, Telerik.Reporting"
    allowLocation="true"
    allowDefinition="Everywhere"/>

        <section
            name="Telerik.ReportDesigner"
            type="Telerik.ReportDesigner.Configuration.ReportDesignerConfigurationSection, Telerik.ReportDesigner.Configuration"
            allowLocation="true"
            allowDefinition="Everywhere"/>    
    </configSections>

    <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/>
    </startup>

      <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
          <!--
          <probing privatePath="path-to-the-assemblies"/>
          -->
          <dependentAssembly>
            <!-- Required for interoperability with older versions of Telerik Reporting -->
            <assemblyIdentity name="Telerik.Reporting" culture="neutral" publicKeyToken="a9d7983dfcc261be"/>
            <bindingRedirect oldVersion="0.0.0.0-13.2.19.1030" newVersion="13.2.19.1030"/>
          </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="Npgsql" culture="neutral"publicKeyToken="5d8b90d52f46fda7"/>
            <codeBase version="4.1.1.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\Npgsql.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Buffers" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.0.3.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Buffers.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="Microsoft.Bcl.AsyncInterfaces" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="1.0.0.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\Microsoft.Bcl.AsyncInterfaces.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Memory" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.0.1.1" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Memory.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Numerics.Vectors" culture="neutral"publicKeyToken="b03f5f7f11d50a3a"/>
            <codeBase version="4.1.4.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Numerics.Vectors.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" culture="neutral"publicKeyToken="b03f5f7f11d50a3a"/>
            <codeBase version="4.0.5.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Runtime.CompilerServices.Unsafe.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Text.Encodings.Web" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.0.4.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Text.Encodings.Web.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Text.Json" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.0.0.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Text.Json.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.Threading.Tasks.Extensions" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.2.0.1" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.Threading.Tasks.Extensions.dll"/>
      </dependentAssembly>
      
      <dependentAssembly>
            <assemblyIdentity name="System.ValueTuple" culture="neutral"publicKeyToken="cc7b13ffcd2ddd51"/>
            <codeBase version="4.0.0.0" href="FILE://C:\Progress\Telerik Reporting R3 2019\Report Designer\System.ValueTuple.dll"/>
      </dependentAssembly>
      
        </assemblyBinding>
      </runtime>

      <connectionStrings>
        <add name="Telerik.Reporting.Examples.CSharp.Properties.Settings.TelerikConnectionString"
            connectionString="TELERIK_CONNECTION_STRING"
            providerName="System.Data.SqlClient" />
      </connectionStrings>
      
      <Telerik.ReportDesigner DefaultWorkingDir="Examples">
      </Telerik.ReportDesigner>

      <system.data>
    <DbProviderFactories>
      <add name="Npgsql Data Provider"
       invariant="Npgsql"
       description=".Net Framework Data Provider for Postgresql Server"
       type="Npgsql.NpgsqlFactory, Npgsql, Version=4.1.1.0, Culture=neutral, PublicKeyToken=5d8b90d52f46fda7" />
    </DbProviderFactories>
      </system.data>
    <!-- Add assembly references -->
    <!--
    <Telerik.Reporting>
    <AssemblyReferences>
    <add name="MyFunctions" version="1.0.0.0" />
    </AssemblyReferences>
    </Telerik.Reporting>
    -->

    <!--  
    <system.diagnostics>
    <trace autoflush="true" indentsize="4">
    <listeners>
    <add name="myListener" type="System.Diagnostics.TextWriterTraceListener" initializeData="C:\Temp\Telerik.ReportDesigner.log" />
    <remove name="Default" />
    </listeners>
    </trace>
    </system.diagnostics>
    -->
    </configuration>

  4. Neli
    Admin
    Neli avatar
    172 posts

    Posted 5 days and 21 hours ago Link to this post

    Hi John,

    Please refer to this forum post - configure standalone report designer for postgresql data source where the same topic is discussed.

    Regards,
    Neli
    Progress Telerik

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top