Service Desk Practitioners Forum
cancel

DB Rule concatenate empty space

Highlighted
SDSKonline
Respected Contributor.

DB Rule concatenate empty space

Hi,

I'm using Service Desk v5 and I'm trying to set a DB rule where two fields get concatenated with a space between them:

Full Name, First Name = John
Full Name, Last Name = Doe

and after the rule I should have:

Name = John Doe

The problem is that I can't insert the empty space between the names. When I try to concatenate " " or ' ' are interpreted as text, and an empty space returns an error saying that the field Value is not filled.

Any solutions?

Thanks
8 REPLIES
Dan Ioan
Honored Contributor.

Re: DB Rule concatenate empty space

Hi,
Can you tell us more about the reason of this needing? Using Name field, you will have the following text: DOE, JOHN. I suppose
that you are trying to use a custom field to put the concatenated value mentioned above.
Cheers,
Dan
SDSKonline
Respected Contributor.

Re: DB Rule concatenate empty space

Hi,

Well, I'm using the Name field, not a custom field.
But what I want is to write the field Name "FirstName LastName", not "LastName, FirstName".

Obviously I could change all my DB records to be "LastName, FirstName", but that would be a last resort solution.

And what if I wanted to add a blank space when concatenating in a custom field? I think there should be a function for this...
Craig R Taylor
Honored Contributor.

Re: DB Rule concatenate empty space

I just finished doing a concatenation rule rewrite last week myself and I found that to put in a space I actually had to go into the field for the value and hit the space bar. I am assuming however that this doesn't work in 5.0?
You can observe a lot just by watching. - YOGI BERRA
SDSKonline
Respected Contributor.

Re: DB Rule concatenate empty space

It doesn't work in v5.
One blank space in the field Value gives an error when pressing the OK button, saying the field Value is required and not filled. When you check back the Value field, after the error, the blank space is no longer there.
Ken Briscoe
Acclaimed Contributor.

Re: DB Rule concatenate empty space

We found a similar bug with SD5 trying to concatenate a blank and carriage return. We ended up using a custom field. You could try this - Have a Custom Text 40 field (eg call it BLANK). Then set BLANK to " ", and concatenate Firstname & BLANK & LastName. Hopefully fixed in SP1 when it eventually arrives.
My email is kenilian@bigpond.com.au
SDSKonline
Respected Contributor.

Re: DB Rule concatenate empty space

Have you actually tryed the BLANK custom field workaround?

I tryed it, after reading about it in this forum, but once again I get the same error, but this time when I try to fill the new custom field with a blank space.

Actually what I did was to set a text custom field and use in the the template with a blank space by default. But writting a blank space in a custom field, when setting the template values, returns an error like: "The field mustn't be empty".
Ken Briscoe
Acclaimed Contributor.

Re: DB Rule concatenate empty space

My apologies...we actually used a " .", and in another case set up a field for " x" where x is a carriage return. So we haven't used just a blank with this technique.
SP1 will re-allow the %lineseparator option....maybe blansk will work too? Regards.....Ken.
My email is kenilian@bigpond.com.au
SDSKonline
Respected Contributor.

Re: DB Rule concatenate empty space

Thanks any way.
I just can't understand how such a simple task as concatenating two text fields with a blank space between could have been neglected by HP developers...