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!

Trim function question

wferroJul 30 2013 — edited Aug 1 2013

I'm very new to SQL and PL/SQL so please be patient with me.  I'm trying to write a select statement for a parameter list of values in Oracle Report Builder.  I need the list of values to contain the unique instrument prefix for each instrument we have.  What I have in the database are unique instrument IDs (prefixes + ID numbers).  I need to trim all but the prefix from these IDs to create the list of values.  I'm not sure how to do this as I wouldn't be trimming the string in the same manner to obtain each instrument prefix.  For example if I have instrument IDs P123, BN1234, 3M123, and IMWR1234 I would need the prefixes to be P, BN, 3M, and IMWR.  Is it possible to use a trim function in this situation or is there another function I should use? Any suggestions?

This post has been answered by Frank Kulash on Jul 30 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 29 2013
Added on Jul 30 2013
5 comments
562 views