-
suppose there are two tables
1_t (a,b,c)
2_t(d,e)
and other_name means to have the alias for the records chose
select a, b
(select d from 2_t where d=1 and e=2) other_name,
from 1_t
where b between 1 and 2
and c = 3
order by a, b;
-
First ...
select a, b, <-- see the comma
-
It would help us a lot if you provide an ORA error you are getting with your query.
At a first glance, I would say your query is missing a comma between column b and your subselect:
select a, b,
(select d from 2_t where d=1 and e=2) other_name,
from 1_t
where b between 1 and 2
and c = 3
order by a, b;
Jurij Modic
ASCII a stupid question, get a stupid ANSI
24 hours in a day .... 24 beer in a case .... coincidence?
-
lose the , after other_name
Oracle DBA and Developer
-
Originally posted by kmesser
lose the , after other_name
Yeah, that too. Good catch!
Jurij Modic
ASCII a stupid question, get a stupid ANSI
24 hours in a day .... 24 beer in a case .... coincidence?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|