School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!

Welcome to Dream.In.Code
Become an Expert!

Join 307,125 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 2,062 people online right now. Registration is fast and FREE... Join Now!




Join two tables from different Oracle schemas

 

Join two tables from different Oracle schemas

MRHooker2u

16 Oct, 2009 - 09:39 AM
Post #1

New D.I.C Head
*

Joined: 2 Jul, 2008
Posts: 2

I am trying to join two tables from different Oracle schemas using a subquery. I can extract data from each of the tables without a problem. The format of the code is copied from a SQL programming manual. When I try to run the application I get the Oracle error 'ORA-00936: missing expression'. Since each SELECT statement executes on its own without error I don't understand what is missing. The query is as follows:

CODE
sql = "SELECT [DD_12809].[PDTABLE_12_1].LINE_ID FROM [DD_12809].[PDTABLE_12_1] JOIN " _
+ "(SELECT [RA_12809].[PDTABLE_201].MAT_DESCRIPTION " _
+ "FROM [RA_12809].[PDTABLE_201]) AS FAB " _
+ "ON [DD_12809].[PDTABLE_12_1].PIPING_MATER_CLASS = FAB.PIPING_MATER_CLASS"


I also tried executing the query using a straight JOIN on the two tables but got the same results. Any insight would be helpful. Thanks!

MRHooker2u


User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 11/21/09 02:22PM

Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month