how to connect visual studio (connect string c# ) on a remote aix 6.1 progress version 9.1a with only 4gl

PascalMBOUM

New Member
please somebody help me i need to get connect on a Progress 9.1a (install on AIx 6.1) using MS visual studio c# . i can get connect to the server using "C:\Program Files (x86)\PROGRESS\bin\prowin32" -pf <PathtoThePfFile> mypfile.pf .It's opened the procedure editor from where i can type request.
I need to know how i can get connect on that remote database (Progress 9.1a on AIX 6.1) using MS visual studio c# on my pc . i can provide my pf file if needed.
 

TomBascom

Curmudgeon
What version of Progress is your prowin32.exe?

A client (such as prowin) can connect to a database that is that same major release or one major release older. Clients cannot connect to databases that are a newer release. So, for instance, a version 11 client can connect to a version 10 database. Or version 11. But not versions 9 or 12.

It is unclear to me how "visual studio c#" is involved here. Especially since you specified "with only 4gl" in your title.

If you are attempting to establish a C# to SQL connection then you need to configure your 9.1a database to accept SQL connections. Your prowin connection shows that the network is working but it does not establish whether or not SQL connections have been configured. You could take a quick look on the AIX side with this command:

Code:
ps -ef | grep sqlsrv2

to see if SQL connections are already configured. If there are any sqlsrv2 processes running then you just need to get the connection credentials from the DBA. If there are no sqlsrv2 processes running then you will need to have the DBA set them up.

On the other hand you might be attempting some other sort of connection from C#. You might be doing something with appservers or "open client" or using some proprietary tooling associated with a particular vendor application. We need to know what, specifically, you need to do in order to help you out with any of that. And, depending on what it is, we might not be much help at all.

Lastly... 9.1a is ancient, obsolete and unsupported. So is AIX 6.1. You (or your employer) should upgrade everything before you throw away money on more development.
 

PascalMBOUM

New Member
thanks a lot for your help. my progress is the version 9.1a on AIX 6.1 .my prowin is the version shipped with progress version 9.1a .I provided some screenshots includind " ps -ef | grep sqlsrv2" result. i don't really know if the dabase server have not sql enable ( like my former Boss told us) because i have try to type a sql expression and it works ! .we need to build app from c# by visual studio with can get data from this serverDB .there is another way to get data from that db without prowin? so that lide a odb driver connector that be used on visual studio?.
thanks in advance
 

Attachments

  • Capture d’écran 2023-09-06 175311.png
    Capture d’écran 2023-09-06 175311.png
    44.4 KB · Views: 4
  • Capture d’écran 2023-09-06 175353.png
    Capture d’écran 2023-09-06 175353.png
    76.8 KB · Views: 4
  • Capture d’écran 2023-09-06 175600.png
    Capture d’écran 2023-09-06 175600.png
    140.7 KB · Views: 3
  • Capture d’écran 2023-09-06 175720.png
    Capture d’écran 2023-09-06 175720.png
    161.8 KB · Views: 2
  • Capture d’écran 2023-09-06 180905.png
    Capture d’écran 2023-09-06 180905.png
    188.9 KB · Views: 4
  • Capture d’écran 2023-09-06 181041.png
    Capture d’écran 2023-09-06 181041.png
    85.2 KB · Views: 3
  • Capture d’écran 2023-09-06 181511.png
    Capture d’écran 2023-09-06 181511.png
    102.3 KB · Views: 4
  • prowin menu.jpg
    prowin menu.jpg
    244.8 KB · Views: 4
  • Capture d’écran 2023-09-06 175002.png
    Capture d’écran 2023-09-06 175002.png
    27.9 KB · Views: 4

TomBascom

Curmudgeon
The prowin32.exe executable is not something that ships with Progress 9.1 for AIX. To have a prowin you must also have a Windows install which might not be the same release as the AIX install. It is important to get the details right or we might give you advice that will be frustratingly wrong.

Your "About Procedure Editor" screen capture confirms that the Windows side of things is Progress 9.1a, so that is now a known answer, but nothing confirms the AIX side.

Your screen captures of "SQL" queries are "embedded" SQL available from within the 4GL engine. This is a dialect of SQL89 but it is not available to non-4GL clients like C#. It is mostly a marketing gimmick, it isn't very useful and it definitely won't help you to connect with C#.

For AIX it would be helpful to "cat $DLC/version". The $DLC environment should point to where Progress was installed. By convention that is usually /usr/dlc but it could have been installed elsewhere. If you are having trouble finding it the following command will search your server for files named "version" (but it might be slow):

Code:
find / -name version -print 2>/dev/null

Your sole AIX screen capture shows that there is no SQL engine running on the AIX side. You will need to find a DBA or learn how to start that if you want to use SQL from C#. If we need to instruct you on starting the SQL engine and establishing connectivity we first need to validate the Progress version on that server.

So to sum it up...

You need to determine what version of Progress is actually running on AIX. The $DLC/version file will tell you that if you can find it.

Also - you really, really ought to upgrade. Working with version 9.1a is going to be very, very painful.
 

PascalMBOUM

New Member
Thanks a lot for your support once more.
according to your instructions, this is what we obtain "PROGRESS Version 9.1A05 as of Fri Mar 24 18:57:47 EST 2000 " on my Progress Aix server terminal. please a look at my screenshot to confirm.
 

Attachments

  • progress version file.jpg
    progress version file.jpg
    164.5 KB · Views: 9
  • start progress proc.jpg
    start progress proc.jpg
    86.1 KB · Views: 9

TomBascom

Curmudgeon
Thanks, that confirms that both the client and the server are running 9.1a. That eliminates a lot of things that could go wrong.

Does this system have anyone filling the DBA role?

Since there is no SQL server currently running you will need to start one. To do that correctly we need to know some things about how the database is being managed and what configuration options are currently in place. The person acting as DBA should be able to answer such questions (and configure a SQL broker) but if there is nobody in that role you are going to have to figure it out yourself.

To start (assuming that there is no proper DBA):

1) What user usually starts the database? You apparently have a "root" login so I am going to go out on a limb and guess that this is one of those sites where root does pretty much everything.

2) Is the db usually started with a script? Or is it configured via conmgr.properties etc?

3) If you run "ps -ef | grep _mprosrv" you will get a list of database server related processes that will help to answer some of these questions.

4) Find the database log file -- DBNAME.lg (replace "DBNAME" with the actual database name, screen capture #6 above has a list of database names, "fbbj92" for example) and search for message "(333)". Find the *last* occurrence of that message in each .lg file and then capture the next 100 lines or so of text. These messages detail the parameters and configuration options specified at startup. Those will go a long way towards guiding the proper configuration for a new SQL broker.

If nobody cares about the health and well being of this system and you just want to thrash away without proper analysis...

Try the following from a root login:

Code:
#  .  /usr/dlc9/bin/proenv
proenv>  proserve /path/fbbj92 -m3 -Mi 5 -Ma 5 -H 192.168.0.1 -S 9999 -ServerType SQL
proenv>  sqlexp -db fbbj92 -H localhost -S 9999 -user root -pass ""

Notes:
  • There is a space between "." and "proenv" in the first command, that will "dot" the proenv script and setup your environment properly for Progress. You will know that it worked because your prompt will change from "#" to "proenv>"
  • The proserve command needs the full path to the target database (without the trailing ".db")
  • The sqlexp command only wants the name of the database - not the full path
  • Change the IP address to reflect the actual IP address or the hostname
  • Change the 9999 port number to something that is not in use, check /etc/services for candidate port numbers
  • I am going out on a limb and guessing that the database was created by the root user and that nobody ever setup a proper SQL DBA; by default the SQL DBA is the user that created the database and if nobody ever did anything no password was ever created either
If you are successful using sqlexp to connect there will be some junk written to the screen and your prompt will change to "SQLExplorer>". You can then execute SQL commands like:

Code:
SQLExplorer> select count(*) from pub.fcompt;
            count(*)
--------------------
              201120
SQLExplorer> quit;

You must preface table names with "PUB.", that is the default "schema" for tables created by the 4GL engine.

If that works then you should be able to connect from Windows by setting up an ODBC connection in the usual manner.

If you skipped the steps about obtaining the configuration and startup information then you may have problems later. There could, for instance, be port conflicts or insufficient resources for connections as well as lots of other stuff that might be unpleasant. We will need the missing configuration details in order to advise you on properly configuring things to avoid those problems.
 
Last edited:

TomBascom

Curmudgeon
Also, 9.1a and AIC 6.1 are still ancient, obsolete, and unsupported. You really need to be pursuing some upgrades.
 

PascalMBOUM

New Member
thanks once more for all.

1) What user usually starts the database ? = root.

2) Is the db usually started with a script? i guess yes because we usually type this "restartbdd" like command as root to restart the databases and we type " shutfbbj92 " to stop i guess both of them are shortcurt aliases to restart and stop all databases . you can see file restartbd.txt
3) If you run "ps -ef | grep _mprosrv" screen capture #1

4) Find the database log file -- DBNAME.lg (replace "DBNAME" with the actual database name, screen capture #6 above has a list of database names, "fbbj92" for example) and search for message "(333)". Find the *last* occurrence of that message in each .lg file and then capture the next 100 lines or so of text. These messages detail the parameters and configuration options specified at startup. Those will go a long way towards guiding the proper configuration for a new SQL broker. screen capture #2 to #3.

i tried to execute ". /usr/dlc9/bin/proenv " as root but no exceeded i switched to my former boss account and tried to execute on it again it succeeded screen capture #5 . Do this means that account "leopold" is the DBA account ?
i didn't go more further after without you advices that because i don't want to create any issues .
Thanks
 

Attachments

  • restartbdd.txt
    4.9 KB · Views: 4
  • Screen Capture proenv .png
    Screen Capture proenv .png
    10.8 KB · Views: 8
  • screen capture of fbbj92.lg.png
    screen capture of fbbj92.lg.png
    208.5 KB · Views: 10
  • screen capture ct-fbbj92.lg.png
    screen capture ct-fbbj92.lg.png
    180.9 KB · Views: 8
  • Capture d’écran 2023-09-09 093544.png
    Capture d’écran 2023-09-09 093544.png
    60 KB · Views: 10
  • Screen Capture gestocks.lg.png
    Screen Capture gestocks.lg.png
    178.6 KB · Views: 6

TomBascom

Curmudgeon
We are getting there :)

Is "leopold" the system's DBA? Is leopold available to help with configuration?

That message about root not being able to "dot" proenv is very strange. I'm going to file that under "ancient and obsolete release of AIX". On the bright side - "proenv" should also work without the dot. So please try to simply run (as root):
Code:
#  /usr/dlc9/bin/proenv
proenv>

The content of "restartbdd" is important. This is probably the startup script for the database. Can you please find and share that file? This command should find it:
Code:
# find / -name restartbdd -print 2>/dev/null

From the initial startup parameters shown in the .lg file it seems that your database is configured to support 400 users. Do you really have that many users?

You are configured to attempt to support as many as 500 tcp/ip connections (but limited to 401 overall so you will never actually get to 500) with -Mn 5 and -Ma 100. The "broker" associated with those connections supports bot SQL and 4GL connections but, since "-Mi 1" is specified, after there are 5 4gl connections no SQL connection is possible with that broker (the first 5 connections will each spawn a "remote server", which will be a 4gl server, and after that any incoming SQL connections will be rejected).

So...

Once we know how many users you really have we can suggest some adjustments and safely launch a SQL broker.

P.S. You also have some fairly awful settings from a performance perspective. But I am going to wait to comment on those until we get your SQL connections working.
 

PascalMBOUM

New Member
Is "leopold" the system's DBA? Is leopold available to help with configuration? NO is not available
i tried "/usr/dlc9/bin/proenv" as root and it works see screen capture #6
the path and content of " restartbdd script" screen capture #1
i found two files which name begings with SqlExplorer screen capture # 10 and #11
 

Attachments

  • Screen Capture cat restartbdd.png
    Screen Capture cat restartbdd.png
    18.3 KB · Views: 3
  • Screen Capture parafbbj .png
    Screen Capture parafbbj .png
    103 KB · Views: 2
  • Screen Capture servpro .png
    Screen Capture servpro .png
    53.6 KB · Views: 2
  • Screen Capture servpro-reseau.png
    Screen Capture servpro-reseau.png
    103.7 KB · Views: 1
  • Screen Capture shutpro .png
    Screen Capture shutpro .png
    46.8 KB · Views: 2
  • Screen Capture proenv en root .png
    Screen Capture proenv en root .png
    10.5 KB · Views: 1
  • Screen Capture SqlExplorer.exception.png
    Screen Capture SqlExplorer.exception.png
    64.5 KB · Views: 1
  • Screen Capture SQLExplorer.properties.png
    Screen Capture SQLExplorer.properties.png
    53.1 KB · Views: 1
Last edited:

TomBascom

Curmudgeon
That looks like the old screen capture where it did not work.

There does not seem to be a screen capture #2.
 

PascalMBOUM

New Member
That looks like the old screen capture where it did not work.

There does not seem to be a screen capture #2.
Sorry on screen capture #1 here we got the result of "/usr/dlc9/bin/proenv" as root
and on screen capture #2 what we have on restartbdd
Thanks !
 

Attachments

  • Screen Capture proenv en root .png
    Screen Capture proenv en root .png
    10.5 KB · Views: 4
  • Screen Capture cat restartbdd.png
    Screen Capture cat restartbdd.png
    18.3 KB · Views: 4
  • Screen Capture SQLExplorer.properties.png
    Screen Capture SQLExplorer.properties.png
    53.1 KB · Views: 4
  • Screen Capture parafbbj .png
    Screen Capture parafbbj .png
    103 KB · Views: 4
  • Screen Capture servpro .png
    Screen Capture servpro .png
    53.6 KB · Views: 4
  • Screen Capture servpro-reseau.png
    Screen Capture servpro-reseau.png
    103.7 KB · Views: 4
  • Screen Capture shutpro .png
    Screen Capture shutpro .png
    46.8 KB · Views: 4
  • Screen Capture SqlExplorer.exception.png
    Screen Capture SqlExplorer.exception.png
    64.5 KB · Views: 4

TomBascom

Curmudgeon
A couple of things...

1) I am truly pleased that you are actually providing answers to questions. That is wonderful. Thank you!

2) Apparently someone tried to run SQLEXP back in 2012

3) It looks like "servpro" and "servpro-reseau" are the scripts that actually start Progress. They also look very "bare bones".

4) Do you *really* have 400 users? That matters because it affects the path to adding SQL connections. If you really do have anything like that many users then we will need to make more detailed adjustments than if you do not.
 

PascalMBOUM

New Member
A couple of things...

1) I am truly pleased that you are actually providing answers to questions. That is wonderful. Thank you!

2) Apparently someone tried to run SQLEXP back in 2012

3) It looks like "servpro" and "servpro-reseau" are the scripts that actually start Progress. They also look very "bare bones".

4) Do you *really* have 400 users? That matters because it affects the path to adding SQL connections. If you really do have anything like that many users then we will need to make more detailed adjustments than if you do not.
4) Do you *really* have 400 users? That matters because it affects the path to adding SQL connections. If you really do have anything like that many users then we will need to make more detailed adjustments than if you do not. // i have created more than 800 users accounts but we already close some of them because those users are not anymore working with us. i have more than 410 active users accounts.
 

PascalMBOUM

New Member
4) Do you *really* have 400 users? That matters because it affects the path to adding SQL connections. If you really do have anything like that many users then we will need to make more detailed adjustments than if you do not. // i have created more than 800 users accounts but we already close some of them because those users are not anymore working with us. i have more than 410 active users accounts.
less than 430 but as recrutment goes on we add users
 

TomBascom

Curmudgeon
Perhaps I should clarify that question - do you have 400 users who need to simultaneously connect to the database?
 

Rob Fitzpatrick

ProgressTalk.com Sponsor
i'm sure that less than 400 users simultaneously connections is ok .let say 300 simultaneously connections will be ok.

let say 350 connections
That is two different answers to the same question.

To configure the brokers appropriately, you need to decide:
  • Maximum concurrent 4GL remote (TCP) clients
  • Maximum concurrent SQL clients
  • Maximum connections overall, including remote 4GL and SQL clients, self-service 4GL clients, utilities, page writers, etc.
 
Top