Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

which is fastest to use: like, instr or substr

295580Dec 14 2007 — edited Feb 4 2008
I was curious about which one gives the fastest return on a query: like, substr or instr?

suppose I have a simple query: "select id from mytable where some_field like &parameter || '%'"
is this much faster or slower than using "where substr(some_field,1,nvl(length(some_field,0))=&parameter"

and how about comparing like and instr?

Thanks in advance
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 3 2008
Added on Dec 14 2007
11 comments
7,443 views