Database provider by Eugene

profile picture

nickinglis

#1
Hi, I'm currently evaluating Wealth-Lab.

One of the things I need is to access data in PostgreSQL, as I have other software working with the data here. I see the database provider extension, but I don't see anyone using it with PostgreSQL. I'm not able to evaluate the extension until I purchase Wealth-Lab, but this is exactly what I need to evaluate to decide whether to purchase it.

Is there anyone using PostgreSQL with Wealth-Lab? Or is there any way to evaluate this extension before purchasing?

Thanks
Nick
profile picture

Eugene

#2
Hi Nick,

The DB provider has been confirmed working with MS SQL Server, MySQL, Oracle. Some ODBC/OLEDB sources like CSV files and MS Access databases were tested too. It was not tested with PostgreSQL.

Update: v2014.03 was tested with PostgreSQL.
profile picture

nickinglis

#3
Thanks Eugene.

Any chance I can try it before purchasing Wealth-Lab?

If I purchase Wealth-Lab, and find that I can't get it working against PostgreSQL, what are the chances that this would get looked at, and the timeframe?

Cheers
N
profile picture

Eugene

#4
I installed latest PostgreSQL x64, started pgAdmin and it failed to connect with "Server doesn't listen" error. Adding 0.0.0.0 to its .conf file didn't help. Does the machine have to be restarted before using the DB?
profile picture

nickinglis

#5
Thanks Eugene! It's /really/ touchy unfortunately.

Is pgAdmin on the same machine as the database? If so, that's a problem I've not seen before. If they're on different machines, then

a) try running pgAdmin on the same machine, or

b) the line you'll need to add to pg_hba.conf will be something like:

host all all 192.168.1.5/32 md5

or

host all all 192.168.1.0/24 md5

or

host all all 192.168.0.0/16 md5

The machine doesn't need to be rebooted to use the database, but postgresql needs to be restarted to see the change to pg_hba.conf.

Any luck?
profile picture

Eugene

#6
Thanks Nick. Managed to set it up successfully. I think the reason was moving the data directory out of Program Files elsewhere at install time. After reinstalling with default parameters the server started working. The helpful installer had an option to install some drivers (Npgsql etc.) but none of them appeared. Had to manually install Npgsql into the GAC. Oh well. Finally, tried to create a table in pgAdmin but couldn't figure out how. Resolved by using psql shell. Next, added a few rows of bogus OHLC data from a CSV file using COPY command.

Although the provider's current version 2013.10 can't link to PostgreSQL database successfully due to syntax errors, it's evident to me where the issue is (was). The fix will be included in the upcoming update (next month). Here's a proof pic of it working in my test environment:




P.S. BTW, how do you connect to PostgreSQL?

P.P.S. I've only tested it with Npgsql 2.1.0.0-rc1 for .NET 4.0 / 4.5 but now that the fix has been factored in, there's no reason for the provider not to work with other drivers.
profile picture

nickinglis

#7
Brilliant. That's fabulous, buying Wealth-Lab now. Certainly excellent support, thanks Eugene!

I didn't have anywhere near the same troubles you had setting PostgreSQL up. I have PostgreSQL installed on my MacBook Pro. I connect to it via pgAdmin and via the Mac version of Aqua Data Studio on the Mac. I have Windows 7 in VMWare Fusion connecting to the network via NAT, and I can connect to PostgreSQL via the Windows version of Aqua Data Studio (which works fine) and via ODBC (which I haven't tested outside of ODBC Admin). I have a user and password set up for the database in question.

On the Mac, I connect with the userid, password, localhost, 5432 and the database name.

On Windows, everything is the same, except that I have the Mac's published network name instead of localhost, but I needed to make the said modifications to pg_hba.conf first, and I had to do that with vi as pgAdmin's tool wouldn't work properly for me. I'm using the PostgreSQL ANSI (x64) driver with default settings, but with connection pooling turned off, because of bad experiences in the past.
profile picture

Eugene

#8
Thanks Nick. If your order comes through before April I'll push the extension update ahead of schedule (this month) so you won't have to wait. Just give me a heads-up if I overlook it.
profile picture

nickinglis

#9
Done! Ordered now, awaiting the activation email.
profile picture

Eugene

#10
Thanks. Your order has been processed, so expect to find your activation key in your inbox.

The provider update has been pushed: Database provider - Release history. Let me know if it works for you.
profile picture

Frank_KXM

#11
Hi,Eugene
I want to download this extension,but I don't have the permission,Can you send a copy to me? Thanks a lot! My email is
CODE:
Please log in to see this code.
profile picture

Eugene

#12
QUOTE:
Hi,Eugene
I want to download this extension,but I don't have the permission,Can you send a copy to me? Thanks a lot! My email is
CODE:
Please log in to see this code.

Hi Frank Kong,

You will have the permission only after purchasing Wealth-Lab Developer. To help you with your purchase decision, the software can be evaluated for free for 30 days. So don't forget to download it and start your free trial.

If using a non-genuine (counterfeit) version obtained from "underground" resources, uninstall it from your hard drive.
profile picture

haemueller

#13
Hi Eugene,

my ambition is the same as nickingli's, namely to set up a tcp connection from/to WealthLab (in a VMware VM) and a PostgreSQL:10.8 docker database on a Linux host. The VM runs .NET up to version 4.7.2. I have installed the Npgsql driver using Visual Studio 2017 on the VM, but now on WL tab "Database provider" no option (under "Select provider") is offered. In your post dated 3/2/2014 you mention that you had to install Npgsql manually into GAC (from GitHub). Another possibility is installing it via Visual Studio - Nuget. I tried both, to no avail even after restarting the VM.

I am running WealthLab Developer 6.9.15.

Any ideas? Is the WL database manager extension limited by .NET version or something like that? AntiVirus or Firewall are not the problem. Please let me know.

Regards,

Hermann
profile picture

Eugene

#14
Hi Hermann,

Sorry that you're having trouble with this. Please try the following:

1. Install an older version of Npgsql which targets .NET 4.0/4.5. The Database provider was tested with the versions 2.1-2.2 from 2014-2015. You can get them here: https://www.nuget.org/packages/Npgsql/

Compatibility with .NET > 4.5 was not tested and cannot be guaranteed.

2. Follow advice from the online user guide in the Wiki:

QUOTE:
Note: if some driver for PostgreSQL doesn't seem to work for you, just try another: dotConnect by DevArt, NPGSQL, PostgreSQL ODBC...

Note that they may be commercial products.

3. Use ODBC or OLEDB to connect to PostgreSQL instead of the native driver (mind the bitness i.e. 64-bit Wealth-Lab can't use 32-bit ODBC drivers, and vice versa). The provider was tested with the native PostgreSQL ODBC driver v9.x:

https://www.postgresql.org/ftp/odbc/versions/msi/
profile picture

quaresma

#15
Hello, We have a PostgreSQL database. Used the wealth lab library to connect to the database and tried OLE DB, ODBC and NpgSQl providers and all of them crashing while performing connection. ODBC is able to connect, but the query sends syntactically incorrect, it puts the name of the table in square brackets (for example [bars]), which leads to an error. Please help us solve problems connecting to our database :)
profile picture

Eugene

#16
Hi,

Please see my suggestion #1 in post #14 above. This looks like the most practical option as it was tested.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).