TD 1.5.1 connect to Oracle

General discussion forum about all databases other than SqlBase.
jwdvorak

TD 1.5.1 connect to Oracle

Post by jwdvorak » 24 Feb 2012, 21:17

I've inherited a set of apps coded with TD 1.5.1, which interface with a SQLBase v8.5 database. We've begun an effort to unload the database and migrate (copy) the DDL and data to Oracle, I need to modify the code in each of the apps to connect to Oracle instead of SQLBase. After we manage to migrate the data, we plan to migrate the code, too... but one step at a time.

I need to know the requirements and best approach to modify the apps to use an Oracle connection. The apps are used by many users, over a wide geographic area - it would be impractical to install, configure and utilize ODBC connections on the client workstations. I'm guessing OLEDB might be the best option, but I read TD may use a native Oracle driver - am I making this more complicated than I need to?

I installed Oracle Client 11g (our standard) on my development workstation, but just read in a post on this forum that TD 2.1 was incompatible with Oracle client later than v9 - so I'm suspecting TD 1.5.1 might not play well with Oracle client 11g, either. I'm afraid some gotcha like that is going to cause me to bang my head on a wall for a week. I'm not even certain whether I need the Oracle client installed on the box, or not.

Nobody in the shop knows anything about Gupta / Centura / TeamDev / SQLBase... I'm attempting to learn by the seat of my pants, but we have no documentation for this old version of TD, and I'm simply flailing. I need advice from someone knowledgeable of this environment.

Thanks in advance for any help...
J. Woody Dvorak

Harald
Germany
Posts: 168
Joined: 30 Mar 2017, 06:16
Location: Rosenheim, Germany

Re: TD 1.5.1 connect to Oracle

Post by Harald » 25 Feb 2012, 00:40

Hi,

I think, the easiest way is to use the Oracle Instant Client (or a network installation of the client software), not OleDB. You only have to copy the files of the instant client in your runtime folder, set the environment variable NLS_LANG, create a tnsnames.ora and set up your sql.ini.

Example for sql.ini:

Code: Select all

....

[win32client.dll]
comdll=sqlora32

[oragtwy]
remotedbname=<yourdbname>,@<yourdatasourcename>
longbuffer=32767
substitute=",
substitute=SYSSQL.,
fetchrow=20
uselob=1
...
Example for tnsnames.ora

Code: Select all

...
<yourdatasourcename>=(DESCRIPTION =(ADDRESS_LIST =(ADDRESS =(COMMUNITY = <yourcommunity>)(PROTOCOL = TCP)(Host = <host_nameor_ip>)(Port = 1521)))(CONNECT_DATA =(SID = <yoursid>)(GLOBAL_NAME = <yourglobalname>)))
...
The uselob=1 in sql.ini is necessary for client > v9 to use Net8. The only challenge is to set the NLS_LANG env var, the easiest way would be to set it with SetEnvironmentVariableA before you connect to the database (see https://support.guptatechnologies.com/supportforum/viewtopic.php?f=30&t=7925). You should also check out the thread https://support.guptatechnologies.com/supportforum/viewtopic.ph ... ant#p23903 .

After you sucessfully connected to the oracle database, you have to make some modifications to the sql statements, for example you have to remove the function prefix @ (@upper(...) is in oracle a upper(...)). You can also use the substitute on sql.ini, for example

Code: Select all

substitute=@upper,upper
Kind Regards
Harald

jwdvorak

Re: TD 1.5.1 connect to Oracle

Post by jwdvorak » 28 Feb 2012, 01:41

Thank you, Harald, for your advice... the info in the other threads looks useful, too. I'll attempt to build a POC application using the techniques described... if I can get it to work, I'll use the techniques to modify the existing apps. jwd

jwdvorak

Re: TD 1.5.1 connect to Oracle

Post by jwdvorak » 28 Feb 2012, 02:21

Uhh... one more quick clarification: reading the TD 1.5.1 compatibility matrix, I see it's compatible with Oracle 8.0.5 (and earlier versions). I read that the various versions of Instant Client available on Oracle's website are backward compatible with Oracle 8, so I downloaded the latest and greatest (v11.2.0.2.0). Is it a reasonable expectation that the latest version of Instant Client files will be recognizable to and correctly utilized by TD 1.5.1?

Jeff Luther

Re: TD 1.5.1 connect to Oracle

Post by Jeff Luther » 29 Feb 2012, 02:05

Is it a reasonable expectation...
If you want a Yes/no, I'd say No. CTD v1.5 was a decade or more ago and lots has happened since then. Might it work? Sure, but a "reasonable expectation"? That may be to optimistic. You asked, but don't let my reply stop you!

Rather than trying to pin someone down with a definitive answer, I have a better reply; Install the Oracle side you are asking about in a 1.5 test environment and see if you can get it to work. Be sure to search this forum too; you may get tidbits of info. on what others have tried and got to working.

User avatar
Charlie
Canada
Posts: 647
Joined: 07 Mar 2017, 18:52
Location: Fredericton, New Brunswick, Canada

Re: TD 1.5.1 connect to Oracle

Post by Charlie » 01 Mar 2012, 16:33

Just in case this is of any help:

To deploy our TD2.1 applications, we used Novell Zenworks Application Virtualization product to capture the Oracle 7 client (the latest Oracle client compatible with TD2.1), the TD2.1 deployment and our application files all setup and working correctly on a bare bones Windows XP computer.

The result of the "virtualization process" is one executable file that contains everything needed by our applications. The executable file can be copied to the host computer, run off a USB key, run off CD, run off the network, a file share, whatever.

Of course, you can pick and choose whatever application virtualization product you wish. Although I haven't tried them, you can look at VMWare's ThinApp (?) and Microsoft's App-V (?); I put question marks there because I'm not quite sure about the names of those products.

Aside: In our case, I didn't like the idea of having to redistribute this one BIG (not that big ... about 150MB) file every time we made a minor change to our application, so we came up with this little trick to keep our application files (our application exe's, qrp's, etc.) outside of the "virtual environment", with a little hook to get a "launcher" application in the virtual environment to load applications sitting outside of the virtual environment.

Cheers and best regards!

Return to “General Discussion”

Who is online

Users browsing this forum: [Ccbot] and 1 guest