• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 274
  • Last Modified:

Script Question, How do I concatenate two fields

Hi Guys

I am doing an import from excel
Normally I would use :
doc.NameAH = result.GetValue( "NameAH" )

However in this case the excell spreadsheet contains First Name Last Name

I would like to concatenate those into one field at import
Can this be done;

James
0
adspmo
Asked:
adspmo
  • 2
  • 2
  • 2
1 Solution
 
HemanthaKumarCommented:
Wouldn't it be like this

firstName = result.GetValue( "NameAH" )
lastName = result.GetValue( "LastNameAH" )
doc.NameAH = lastName + "," + firstName


~Hemanth
0
 
adspmoAuthor Commented:
Hey I will try that out

Thanx

james
0
 
qwaleteeCommented:
Or rather,

firstName = result.GetValue( "NameAH" )
lastName = result.GetValue( "LastNameAH" )
doc.NameAH = firstName + " " + lastName

Or

doc.NameAH = firstName & " " & lastName

I take it you are using LotusScript to access Excel via OLE Automation?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
adspmoAuthor Commented:
Yupp

I am using ODBC to import one time into Notes
0
 
HemanthaKumarCommented:
wasn't that the same answer that I gave you James.. are you going blind here ??
0
 
qwaleteeCommented:
No, Hemanth, you deserved much of the points.  I corrected the order, that's all.  You had "ln, fn" where James wanted "fn ln".  if James had asked, I would have suggested 130 to you, 120 to me.
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 2
  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now