Problem using the sample -Oracle Stored Procedures template

Anything that doesn't fall into the defect or enhancement categories

Problem using the sample -Oracle Stored Procedures template

Postby namellac on Fri Sep 10, 2004 10:52 pm

I'm able to connect to the database when I execute the template, and it lists the databases in the \"Select a database\" dropdown, but after selecting, there are no tables in the \"Select tables\" list box. Am I doing something wrong? Testing the Connection under \"Default Settings\" is successful.

Thanks,

Craig
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby mike.griffin on Sat Sep 11, 2004 12:59 am

I just tested this here on my machine, generated them fine, here's my connection string:

Provider=OraOLEDB.Oracle.1;Password=yadayada;Persist Security Info=True;User ID=GRIFFO;Data Source=dbMeta


It might be a security thing, can you browse the full tree in the MyMeta Browser tree window within MyGeneration. Try choosing the stock \"HR\" database and selecting EMPLOYEEs. It works, we have lots of Oracle folks.

Sample of what I generated:

Code: Select all
DECLARE n VARCHAR(256);
BEGIN
SELECT OBJECT_NAME INTO n FROM SYS.ALL_OBJECTS WHERE OBJECT_NAME = 'MYGEN' AND OWNER = 'HR';
EXCEPTION
WHEN NO_DATA_FOUND THEN
EXECUTE IMMEDIATE 'CREATE PACKAGE HR.MYGEN IS TYPE sqlcur IS REF CURSOR; END MYGEN;';
END;
/

CREATE OR REPLACE PROCEDURE \"HR\".\"PK_EMPLOYEES\"
(
   p_EMPLOYEE_ID IN EMPLOYEES.EMPLOYEE_ID%type,
    outCursor OUT HR.MYGEN.sqlcur
)
IS
BEGIN
    OPEN outCursor FOR
   SELECT
      EMPLOYEE_ID,
      FIRST_NAME,
      LAST_NAME,
      EMAIL,
      PHONE_NUMBER,
      HIRE_DATE,
      JOB_ID,
      SALARY,
      COMMISSION_PCT,
      MANAGER_ID,
      DEPARTMENT_ID
   FROM EMPLOYEES
   WHERE
      EMPLOYEE_ID = p_EMPLOYEE_ID
;
END PK_EMPLOYEES;
/
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Connection string different

Postby namellac on Mon Sep 13, 2004 2:34 pm

The main difference I see in the connect string is the Provider.

If I try the OraOLEDB.Oracle.1 I get an error box \"The OraOLEDB.Oracle.1 provider is not registered on the local machine\"

When I generate the string through the OLEDB button it uses a connection string of

Provider=MSDAORA.1;Password=passw;User ID=UID;Data Source=PHXDEV2;Persist Security Info=True

This is the same connect string I use in TOAD and VB.NET
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby mike.griffin on Mon Sep 13, 2004 2:39 pm

Yes, we use the Oracle Provider for OLEDB to pull the meta data.
http://www.oracle.com/technology/sample_code/tech/windows/ole_db/oledb92/index.html You should have it automatically if you've installed Oracle, check the link above.

MyGeneration uses OLEDB providers (when available) to pull meta data.
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby mike.griffin on Mon Sep 13, 2004 2:42 pm

User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby namellac on Mon Sep 13, 2004 4:02 pm

Dowloaded, but the install isn't working for some reason.
I like the look of your product. It seems much easier to use than Sheridan's Code Assist.

I hope I can get this to work!
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby mike.griffin on Mon Sep 13, 2004 4:29 pm

Well, I'm pretty sure it's a checkbox on the Oracle install, that how I installed it, it just came with Oracle, go though your install again and look at the settings, trust me, you'll love it when you get it working !!
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby namellac on Mon Sep 13, 2004 6:03 pm

Are you considering writing conversions for Sheridan Code Assist files?

The syntax looks very similar.


I'll keep hacking on getting the OLEDB working.
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby namellac on Tue Sep 14, 2004 4:33 pm

some bad news. I've been informed that the Proprietary application we use in house uses Oracle and requires the \"Provider=MSDAORA\" and NOT to install the OraOLEDB on my local workstation. :evil:

Interesting to note that the MyMeta Browser in MyGeneration does show the Databases and Stored Procs, but that is all. I have admin rights to the database.

Suggestions?
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby mike.griffin on Tue Sep 14, 2004 5:08 pm

You're getting a little confused :wink: , MyGeneration uses that driver to pull meta data, you can use any driver you want in the appilication that would generate with MyGeneration, for example, our Oracle dOOdads use OracleClient, the .NET managed data provider. Some folks use ODP.NET.

Again, the driver that MyGeneration uses to pull meta-data has no impact on what your application would use, I would assume you're going to use MyGeneration to generate some code, if so, that code can target any driver on the planet.

Now, if you're company is saying you cannot use the the OLEDB Driver that oracle provides for free, just to make MyGeneration run that's suprising? You can use MSADORA in your app, but MyGeneration uses the Oracle OLEDB provider to run.
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby mike.griffin on Tue Sep 14, 2004 5:10 pm

If you want to add type mapping from oracle types to MSADORA DbTarget types thats fine, just do it in the docking window, however, if you can't install the Oracle OLEDB Driver (and it only has to be on one machine? you're company is willing to use Oracle but not install their driver??) then MyGeneration will be no use to you, I am sorry.

The MSDAORA doesn't support the OLEDB meta services to the degree that we need in MyGeneration.
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby namellac on Wed Sep 15, 2004 9:52 pm

Apparently I was misinformed. The Oracle Objects for OLE are installed on my computer. They are version 2.2.1.0. Are these too old?
It doesn't show up in the Edit Default Settings.
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby mike.griffin on Thu Sep 16, 2004 12:53 am

Do you see \"Oracle Provider for OLE DB\" in the Provider Tab the the Data Link Properties dialog when trying to connect in MyGeneration, if so, that's it, try connecting.
User avatar
mike.griffin
Site Admin
 
Posts: 3290
Joined: Sat Apr 03, 2004 6:10 am
Location: Indianapolis, IN

Postby namellac on Thu Sep 16, 2004 2:23 pm

No, I'm not seeing it in the list. I've gone through the Oracle installer to make sure that the \"Oracle Objects for OLE 2.2.1.0.0\" were installed.
I've uninstalled, rebooted. Reinstalled, Rebooted. Still doesn't show up.
This is the version associated with Oracle 7.34. Legacy App that can't be upgraded, unfortunately.

Is there something I can check in the registry? or is it a file pathing scenario?
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm

Postby namellac on Thu Sep 16, 2004 2:50 pm

This is the screen from the ORACLE install

http://www.hi-def-howlers.com/oracle.JPG

Had to use my band site, I don't have access to our external web server here.
namellac
Lurker
 
Posts: 8
Joined: Fri Sep 10, 2004 10:45 pm


Return to General Questions or Comments

Who is online

Users browsing this forum: No registered users and 0 guests