[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.sqlserver.programming

Replacing Coma during concatenation

Jami

3/30/2007 4:04:00 PM


dear all

if there is value null in first name or last name column then how can
eliminate the coma that it should not come in the out put e.g if first
name is Ali and last name is null then 'Ali' should b the output not
',Ali' how it can b possible

SELECT LastName + ', ' + FirstName AS Moniker
FROM Employees
WHERE Region = 'WA'

Regards,
Jami.



*** Sent via Developersdex http://www.develop... ***
20 Answers

Tony Rogerson

3/30/2007 4:06:00 PM

0

SELECT COALESCE( LastName + ', ', '' ) + FirstName AS Moniker


--
Tony Rogerson, SQL Server MVP
http://sqlblogcasts.com/blogs/to... (Ramblings from the field from a
SQL consultant)
http://sqlser... (UK SQL User Community)

"Jami" <jami.khan@yahoo.com> wrote in message
news:OyKj4TucHHA.3408@TK2MSFTNGP03.phx.gbl...
>
> dear all
>
> if there is value null in first name or last name column then how can
> eliminate the coma that it should not come in the out put e.g if first
> name is Ali and last name is null then 'Ali' should b the output not
> ',Ali' how it can b possible
>
> SELECT LastName + ', ' + FirstName AS Moniker
> FROM Employees
> WHERE Region = 'WA'
>
> Regards,
> Jami.
>
>
>
> *** Sent via Developersdex http://www.develop... ***

bzlrbi

12/12/2011 5:29:00 PM

0

On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3jane@yahoo.com>
wrote:

>On Dec 12, 11:43?am, Gladys <j...@cant.say.it.anymore> wrote:
>> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>>
>> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
>> > this week's victims were the Bears, a team riddled with injuries on offense.
>>
>> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
>> > yarder to win it.
>> > both looked like they'd have been good from 70.
>>
>> It's too bad that we didn't make the 28 yarder that was blocked - it
>> would have been a bit less difficult on the nerves.
>>
>> I have no idea what to say about yesterday's game - it was one of the
>> most incredible endings to a football game that I have ever seen.
>> Un-freaking-believeble.
>>
>> Love him or hate him - Tebow is fun as hell to watch.
>>
>It was one of the most exciting endings I've seen in awhile. The
>Broncos got themselves a pretty good kicker, those FGs looked like
>kickoffs

I'm not sure if that, or the end of the Giants game was more
incredible.

the felonious kidd

12/12/2011 5:43:00 PM

0

On Dec 12, 9:28 am, bzl...@aaool.com wrote:
> On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3j...@yahoo.com>
> wrote:
>
>
>
>
>
>
>
>
>
> >On Dec 12, 11:43 am, Gladys <j...@cant.say.it.anymore> wrote:
> >> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>
> >> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
> >> > this week's victims were the Bears, a team riddled with injuries on offense.
>
> >> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
> >> > yarder to win it.
> >> > both looked like they'd have been good from 70.
>
> >> It's too bad that we didn't make the 28 yarder that was blocked - it
> >> would have been a bit less difficult on the nerves.
>
> >> I have no idea what to say about yesterday's game - it was one of the
> >> most incredible endings to a football game that I have ever seen.
> >> Un-freaking-believeble.
>
> >> Love him or hate him - Tebow is fun as hell to watch.
>
> >It was one of the most exciting endings I've seen in awhile.  The
> >Broncos got themselves a pretty good kicker,  those FGs looked like
> >kickoffs
>
> I'm not sure if that, or the end of the Giants game was more
> incredible.

Texans vs Bengals ending was pretty dang good too. I'm not fond of
Texas but we have a tender spot for Kubiak. And hey the Saints vs
Titans finish wasn't bad either.

Neil X

12/12/2011 8:48:00 PM

0

On Dec 12, 12:43 pm, the felonious kidd <bob_a...@hotmail.com> wrote:
> On Dec 12, 9:28 am, bzl...@aaool.com wrote:
>
>
>
>
>
>
>
>
>
> > On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3j...@yahoo.com>
> > wrote:
>
> > >On Dec 12, 11:43 am, Gladys <j...@cant.say.it.anymore> wrote:
> > >> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>
> > >> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
> > >> > this week's victims were the Bears, a team riddled with injuries on offense.
>
> > >> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
> > >> > yarder to win it.
> > >> > both looked like they'd have been good from 70.
>
> > >> It's too bad that we didn't make the 28 yarder that was blocked - it
> > >> would have been a bit less difficult on the nerves.
>
> > >> I have no idea what to say about yesterday's game - it was one of the
> > >> most incredible endings to a football game that I have ever seen.
> > >> Un-freaking-believeble.
>
> > >> Love him or hate him - Tebow is fun as hell to watch.
>
> > >It was one of the most exciting endings I've seen in awhile.  The
> > >Broncos got themselves a pretty good kicker,  those FGs looked like
> > >kickoffs
>
> > I'm not sure if that, or the end of the Giants game was more
> > incredible.
>
> Texans vs Bengals ending was pretty dang good too. I'm not fond of
> Texas but we have a tender spot for Kubiak. And hey the Saints vs
> Titans finish wasn't bad either.


Skins/Pats had a nail biting ending too. Brady throws a pick in the
end zone that stops a drive that would have put them up by 2 scores.
Redskins march the length of the field before Mayo picks off Grossman
inside the 10 yard line with 20 seconds left in the game. Lots of
drama last weekend.

Peace,
Neil X.

marcman

12/12/2011 9:04:00 PM

0

On Dec 12, 11:58 am, "3jane." <q3j...@yahoo.com> wrote:
> On Dec 12, 11:43 am, Gladys <j...@cant.say.it.anymore> wrote:
>
>
>
>
>
>
>
> > On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>
> > > another 4th Qte comeback from 10 down to win 13-10 in overtime,
> > > this week's victims were the Bears, a team riddled with injuries on offense.
>
> > > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
> > > yarder to win it.
> > > both looked like they'd have been good from 70.
>
> > It's too bad that we didn't make the 28 yarder that was blocked - it
> > would have been a bit less difficult on the nerves.
>
> > I have no idea what to say about yesterday's game - it was one of the
> > most incredible endings to a football game that I have ever seen.
> > Un-freaking-believeble.
>
> > Love him or hate him - Tebow is fun as hell to watch.
>
> It was one of the most exciting endings I've seen in awhile.  The
> Broncos got themselves a pretty good kicker,  those FGs looked like
> kickoffs

Prater has a history of long FGs because he kicks outdoors in Denver
where the air is thin a mile high . . .

Gladys

12/12/2011 9:37:00 PM

0

On 12/12/2011 2:03 PM, marcman wrote:

>> It was one of the most exciting endings I've seen in awhile. The
>> Broncos got themselves a pretty good kicker, those FGs looked like
>> kickoffs
>
> Prater has a history of long FGs because he kicks outdoors in Denver
> where the air is thin a mile high . . .

Prater sucks. His field goal percentage is terrible, one of the worst in
the NFL. He has made some clutch kicks when he needs to, but he has
missed FAR too many routine field goals this year, including a 28 yarder
against the bears that was blocked because it was kicked at too low of a
trajectory. If he had made that one he wouldn't have needed the bears to
make a bonehead play late in the game (stopping the clock) and then the
59 yarder. Oh, and thank the baby Jesus for the fumble in overtime. I
feel sorry for Marion Barber - dude played a solid game and then totally
handed it to the Broncos at the end.... Anyway...

Can you pick out marcman in this video? :

http://www.youtube.com/watch?feature=player_embedded&v=z...

:-)

Gladys.


--- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---

3jane.

12/12/2011 11:00:00 PM

0

On Dec 12, 3:48 pm, "Neil X." <nei...@yahoo.com> wrote:
> On Dec 12, 12:43 pm, the felonious kidd <bob_a...@hotmail.com> wrote:
>
>
>
>
>
> > On Dec 12, 9:28 am, bzl...@aaool.com wrote:
>
> > > On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3j...@yahoo.com>
> > > wrote:
>
> > > >On Dec 12, 11:43 am, Gladys <j...@cant.say.it.anymore> wrote:
> > > >> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>
> > > >> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
> > > >> > this week's victims were the Bears, a team riddled with injuries on offense.
>
> > > >> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
> > > >> > yarder to win it.
> > > >> > both looked like they'd have been good from 70.
>
> > > >> It's too bad that we didn't make the 28 yarder that was blocked - it
> > > >> would have been a bit less difficult on the nerves.
>
> > > >> I have no idea what to say about yesterday's game - it was one of the
> > > >> most incredible endings to a football game that I have ever seen.
> > > >> Un-freaking-believeble.
>
> > > >> Love him or hate him - Tebow is fun as hell to watch.
>
> > > >It was one of the most exciting endings I've seen in awhile.  The
> > > >Broncos got themselves a pretty good kicker,  those FGs looked like
> > > >kickoffs
>
> > > I'm not sure if that, or the end of the Giants game was more
> > > incredible.
>
> > Texans vs Bengals ending was pretty dang good too. I'm not fond of
> > Texas but we have a tender spot for Kubiak. And hey the Saints vs
> > Titans finish wasn't bad either.
>
> Skins/Pats had a nail biting ending too.  Brady throws a pick in the
> end zone that stops a drive that would have put them up by 2 scores.
> Redskins march the length of the field before Mayo picks off Grossman
> inside the 10 yard line with 20 seconds left in the game.  Lots of
> drama last weekend.
>
After Moss gets a TD called back for O pass interference in the end
zone. Bad teams find a way to lose games, that's the Redskins this
year (again). If the Pats don't shore up that D, they're in for some
hurt in the playoffs, you can't outscore everybody.

bzlrbi

12/12/2011 11:24:00 PM

0

On Mon, 12 Dec 2011 15:00:00 -0800 (PST), "3jane." <q3jane@yahoo.com>
wrote:

>On Dec 12, 3:48?pm, "Neil X." <nei...@yahoo.com> wrote:
>> On Dec 12, 12:43?pm, the felonious kidd <bob_a...@hotmail.com> wrote:
>>
>>
>>
>>
>>
>> > On Dec 12, 9:28?am, bzl...@aaool.com wrote:
>>
>> > > On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3j...@yahoo.com>
>> > > wrote:
>>
>> > > >On Dec 12, 11:43?am, Gladys <j...@cant.say.it.anymore> wrote:
>> > > >> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>>
>> > > >> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
>> > > >> > this week's victims were the Bears, a team riddled with injuries on offense.
>>
>> > > >> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
>> > > >> > yarder to win it.
>> > > >> > both looked like they'd have been good from 70.
>>
>> > > >> It's too bad that we didn't make the 28 yarder that was blocked - it
>> > > >> would have been a bit less difficult on the nerves.
>>
>> > > >> I have no idea what to say about yesterday's game - it was one of the
>> > > >> most incredible endings to a football game that I have ever seen.
>> > > >> Un-freaking-believeble.
>>
>> > > >> Love him or hate him - Tebow is fun as hell to watch.
>>
>> > > >It was one of the most exciting endings I've seen in awhile. ?The
>> > > >Broncos got themselves a pretty good kicker, ?those FGs looked like
>> > > >kickoffs
>>
>> > > I'm not sure if that, or the end of the Giants game was more
>> > > incredible.
>>
>> > Texans vs Bengals ending was pretty dang good too. I'm not fond of
>> > Texas but we have a tender spot for Kubiak. And hey the Saints vs
>> > Titans finish wasn't bad either.
>>
>> Skins/Pats had a nail biting ending too. ?Brady throws a pick in the
>> end zone that stops a drive that would have put them up by 2 scores.
>> Redskins march the length of the field before Mayo picks off Grossman
>> inside the 10 yard line with 20 seconds left in the game. ?Lots of
>> drama last weekend.
>>
>After Moss gets a TD called back for O pass interference in the end
>zone. Bad teams find a way to lose games, that's the Redskins this
>year (again). If the Pats don't shore up that D, they're in for some
>hurt in the playoffs, you can't outscore everybody.

Just like the G-men. Eli can't win every game by himself, unless he
can play free safety too.

marcman

12/13/2011 12:54:00 AM

0

On Dec 12, 4:36 pm, Gladys <j...@cant.say.it.anymore> wrote:
> On 12/12/2011 2:03 PM, marcman wrote:
>
> >> It was one of the most exciting endings I've seen in awhile.  The
> >> Broncos got themselves a pretty good kicker,  those FGs looked like
> >> kickoffs
>
> > Prater has a history of long FGs because he kicks outdoors in Denver
> > where the air is thin a mile high . . .
>
> Prater sucks.

Your whole team sucks.

> His field goal percentage is terrible, one of the worst in
> the NFL.  He has made some clutch kicks when he needs to, but he has
> missed FAR too many routine field goals this year, including a 28 yarder
> against the bears that was blocked because it was kicked at too low of a
> trajectory.

You quoted me stating that Prater has a history of kicking long field
goals due to the thin air in Denver, yet your rant is in an entirely
different direction.

> If he had made that one he wouldn't have needed the bears to
> make a bonehead play late in the game (stopping the clock) and then the
> 59 yarder. Oh, and thank the baby Jesus for the fumble in overtime. I
> feel sorry for Marion Barber - dude played a solid game and then totally
> handed it to the Broncos at the end.... Anyway...
>
> Can you pick out marcman in this video? :
>
> http://www.youtube.com/watch?feature=player_embedded&v=z...
>
> :-)
>
> Gladys.

It's not my fault the future of your team is in the hands of a sub par
bible thumping annoying gadfly, Gladys.

Neil X

12/13/2011 4:04:00 PM

0

On Dec 12, 6:00 pm, "3jane." <q3j...@yahoo.com> wrote:
> On Dec 12, 3:48 pm, "Neil X." <nei...@yahoo.com> wrote:
>
>
>
>
>
>
>
> > On Dec 12, 12:43 pm, the felonious kidd <bob_a...@hotmail.com> wrote:
>
> > > On Dec 12, 9:28 am, bzl...@aaool.com wrote:
>
> > > > On Mon, 12 Dec 2011 08:58:39 -0800 (PST), "3jane." <q3j...@yahoo.com>
> > > > wrote:
>
> > > > >On Dec 12, 11:43 am, Gladys <j...@cant.say.it.anymore> wrote:
> > > > >> On 12/11/2011 5:23 PM, Ray O'Hara wrote:
>
> > > > >> > another 4th Qte comeback from 10 down to win 13-10 in overtime,
> > > > >> > this week's victims were the Bears, a team riddled with injuries on offense.
>
> > > > >> > and props to the Broncs kicker who hit a 59 yarder to tie the game and a 51
> > > > >> > yarder to win it.
> > > > >> > both looked like they'd have been good from 70.
>
> > > > >> It's too bad that we didn't make the 28 yarder that was blocked - it
> > > > >> would have been a bit less difficult on the nerves.
>
> > > > >> I have no idea what to say about yesterday's game - it was one of the
> > > > >> most incredible endings to a football game that I have ever seen.
> > > > >> Un-freaking-believeble.
>
> > > > >> Love him or hate him - Tebow is fun as hell to watch.
>
> > > > >It was one of the most exciting endings I've seen in awhile.  The
> > > > >Broncos got themselves a pretty good kicker,  those FGs looked like
> > > > >kickoffs
>
> > > > I'm not sure if that, or the end of the Giants game was more
> > > > incredible.
>
> > > Texans vs Bengals ending was pretty dang good too. I'm not fond of
> > > Texas but we have a tender spot for Kubiak. And hey the Saints vs
> > > Titans finish wasn't bad either.
>
> > Skins/Pats had a nail biting ending too.  Brady throws a pick in the
> > end zone that stops a drive that would have put them up by 2 scores.
> > Redskins march the length of the field before Mayo picks off Grossman
> > inside the 10 yard line with 20 seconds left in the game.  Lots of
> > drama last weekend.
>
> After Moss gets a TD called back for O pass interference in the end
> zone.  Bad teams find a way to lose games, that's the Redskins this
> year (again).  If the Pats don't shore up that D, they're in for some
> hurt in the playoffs, you can't outscore everybody.


Folks are pretty appalled by the Pats defense around Boston. We all
love Belichick, but his personnel decisions in the secondary over the
past 3-4 years have been, well, "below abysmal" is the only way to
describe it.

Peace,
Neil X.