Re: Excel formula question

From: Curtis Leung <leungcu_at_berkeley.edu>
Date: Tue, 21 Nov 2006 11:54:34 -0800

Hi Monica,

The most direct solution: you can try putting an IF condition on each "-".

For example:

=CONCATENATE(S3,IF(T3="","","-"),T3,IF(U3="","","-"),U3,IF(V3="","","-"),V3,IF(W3="","","-"),W3)

or some variation of this formula.

Curtis

Monica Mack wrote:
> I put together spreadsheets with cable ID information for uploading
> into our database. The cables are broken down into individual columns
> for Bldg TR, Room#, Seq.#, D or V. From these columns I want to create
> a column that indicates the cableID as it might appear on a label. For
> example MOFFIT-312-321-005-D
> To get this I use the Concatenate command:
> =CONCATENATE(S3,"-",T3,"-",U3,"-",V3,"-",W3)
> This takes the value in each column and inserts a dash between them.
>
> My problem is that not all cable ID's (older one) have all columns.
> For example MOFFIT-201-1
> In this case I end up getting double dashes or a dash at the end so it
> ends up looking like this: MOFFIT--201-1-
>
> Does anyone know what else I can add to the formula so it doesn't
> double up the dashes or add to the end?
>
> Thanks in advance for assistance.
>
> Monica
>
>
> ------------------------------------------------------------------------
> The following was automatically added to this message by the list server:
>
> For information about Micronet, including subscribing to
> or unsubscribing from its mailing list and finding out
> about upcoming meetings, please visit the Micronet Web site:
> <http://micronet.berkeley.edu/>.

------------------------------------------------------------------------
The following was automatically added to this message by the list server:

For information about Micronet, including subscribing to
or unsubscribing from its mailing list and finding out
about upcoming meetings, please visit the Micronet Web site:
<http://micronet.berkeley.edu/>.
Received on Tue Nov 21 2006 - 12:15:32 PST

This archive was generated by hypermail 2.2.0 : Tue Nov 21 2006 - 12:15:33 PST