dbTalk Databases Forums  

doing hints on view

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss doing hints on view in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #11  
Old   
DA Morgan
 
Posts: n/a

Default Re: doing hints on view - 02-07-2008 , 11:19 AM






Eitan M wrote:
Quote:
How can I do instead of using package in my example, use a standard sql.

select
t.column_1, t.column_2,
t2.name , ...
where t2.name = t.
my_package.my_func(t.column_1, '2') ...
from my_table t, my_table2 t2
where t2.name = t.name || ' - 1' (*)

the (*) doesn't work.
What should I do instead ?

Thanks
You should never use "*" for anything in production code so rather than
asking us how to make bad code work how about describing the business
problem you are trying to address.
--
Daniel A. Morgan
Oracle Ace Director & Instructor
University of Washington
damorgan@x.washington.edu (replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org


Reply With Quote
  #12  
Old   
DA Morgan
 
Posts: n/a

Default Re: doing hints on view - 02-07-2008 , 11:19 AM






Eitan M wrote:
Quote:
How can I do instead of using package in my example, use a standard sql.

select
t.column_1, t.column_2,
t2.name , ...
where t2.name = t.
my_package.my_func(t.column_1, '2') ...
from my_table t, my_table2 t2
where t2.name = t.name || ' - 1' (*)

the (*) doesn't work.
What should I do instead ?

Thanks
You should never use "*" for anything in production code so rather than
asking us how to make bad code work how about describing the business
problem you are trying to address.
--
Daniel A. Morgan
Oracle Ace Director & Instructor
University of Washington
damorgan@x.washington.edu (replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org


Reply With Quote
  #13  
Old   
DA Morgan
 
Posts: n/a

Default Re: doing hints on view - 02-07-2008 , 11:19 AM



Eitan M wrote:
Quote:
How can I do instead of using package in my example, use a standard sql.

select
t.column_1, t.column_2,
t2.name , ...
where t2.name = t.
my_package.my_func(t.column_1, '2') ...
from my_table t, my_table2 t2
where t2.name = t.name || ' - 1' (*)

the (*) doesn't work.
What should I do instead ?

Thanks
You should never use "*" for anything in production code so rather than
asking us how to make bad code work how about describing the business
problem you are trying to address.
--
Daniel A. Morgan
Oracle Ace Director & Instructor
University of Washington
damorgan@x.washington.edu (replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org


Reply With Quote
  #14  
Old   
Mark D Powell
 
Posts: n/a

Default Re: doing hints on view - 02-09-2008 , 07:44 PM



On Feb 7, 7:10*am, Gints Plivna <gints.pli... (AT) gmail (DOT) com> wrote:
Quote:
cannot find any reason to use user defined functions at all in this
case. You can do all that in just one SQL statement, it would be much
faster and better understandable.

Gints Plivnahttp://www.gplivna.eu
I am guessing that the example is more or less made up by stripping
out all the real logic. I think that the hint would need to be in the
package on the cursor rather than in the view but without a better
explanation of why a packagted function is being used it is very
difficult to try to determine what the heck is the point of the code.

HTH -- Mark D Powell --




Reply With Quote
  #15  
Old   
Mark D Powell
 
Posts: n/a

Default Re: doing hints on view - 02-09-2008 , 07:44 PM



On Feb 7, 7:10*am, Gints Plivna <gints.pli... (AT) gmail (DOT) com> wrote:
Quote:
cannot find any reason to use user defined functions at all in this
case. You can do all that in just one SQL statement, it would be much
faster and better understandable.

Gints Plivnahttp://www.gplivna.eu
I am guessing that the example is more or less made up by stripping
out all the real logic. I think that the hint would need to be in the
package on the cursor rather than in the view but without a better
explanation of why a packagted function is being used it is very
difficult to try to determine what the heck is the point of the code.

HTH -- Mark D Powell --




Reply With Quote
  #16  
Old   
Mark D Powell
 
Posts: n/a

Default Re: doing hints on view - 02-09-2008 , 07:44 PM



On Feb 7, 7:10*am, Gints Plivna <gints.pli... (AT) gmail (DOT) com> wrote:
Quote:
cannot find any reason to use user defined functions at all in this
case. You can do all that in just one SQL statement, it would be much
faster and better understandable.

Gints Plivnahttp://www.gplivna.eu
I am guessing that the example is more or less made up by stripping
out all the real logic. I think that the hint would need to be in the
package on the cursor rather than in the view but without a better
explanation of why a packagted function is being used it is very
difficult to try to determine what the heck is the point of the code.

HTH -- Mark D Powell --




Reply With Quote
  #17  
Old   
Mark D Powell
 
Posts: n/a

Default Re: doing hints on view - 02-09-2008 , 07:44 PM



On Feb 7, 7:10*am, Gints Plivna <gints.pli... (AT) gmail (DOT) com> wrote:
Quote:
cannot find any reason to use user defined functions at all in this
case. You can do all that in just one SQL statement, it would be much
faster and better understandable.

Gints Plivnahttp://www.gplivna.eu
I am guessing that the example is more or less made up by stripping
out all the real logic. I think that the hint would need to be in the
package on the cursor rather than in the view but without a better
explanation of why a packagted function is being used it is very
difficult to try to determine what the heck is the point of the code.

HTH -- Mark D Powell --




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.