Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: How to add text string to query response? Help :-(

Re: How to add text string to query response? Help :-(

From: Sparky <mark_ponsford_at_hotmail.com>
Date: 5 Nov 2004 01:36:31 -0800
Message-ID: <6442e48.0411050136.35a98396@posting.google.com>


Thanks for the magic word "concatenation". :-)

"Access" <idmwarpzone_NOSPAM__at_yahoo.com> wrote in message news:<418a9160$0$2970$ba620e4c_at_news.skynet.be>...
> "Sparky" <mark_ponsford_at_hotmail.com> wrote in message
> news:6442e48.0411040900.1c70fac9_at_posting.google.com...
> > I'm trying to return a rescord from an oracle db surrounded(wrapped
> > by) by 2 text strings
> >
> > Example -
> >
> > Select p.p_id
> > from person p
> > where p.p_name like '%smith%'
> >
> > returns a list of p_id records -
> >
> > 1243
> > 1236
> > 4523
> > 2355
> >
> >
> >
> > But I want to put a text string before and after each record to make
> > them links so I'd get the following repsonse -
> >
> > <a href="http://www.person.com/person.asp?person=1243">Show person</a>
> > <a href="http://www.person.com/person.asp?person=1236">Show person</a>
> > <a href="http://www.person.com/person.asp?person=4523">Show person</a>
> > <a href="http://www.person.com/person.asp?person=2355">Show person</a>
> >
> > I've been trying stuff like (admittedly MS style)
> >
> > Select '<a href="http://www.person.com/person.asp?person=' + p.p_id +
> > '">Show person</a>'
> > from person p
> > where p.p_name like '%smith%'
> >
> > but just end up with syntax errors every time.
> >
> > Can anyone help?
> >
> > I'm sure the answer is simple but I've been googling for an hour!
>
> 1 second of Google :
> http://www.google.be/search?hl=en&q=oracle+sql+string+concatenation&meta=
Received on Fri Nov 05 2004 - 03:36:31 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US