Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 421
  • Last Modified:

How to create a composite field with a dynamic value plus a static value ?

I created an Access Interface on which the user can maintain an Access SQL Server table. The table is comprised of fields
as follows:

                             BRANCH NUMBER           EMAIL ADDRESS PREFIX             EMAIL ADDRESS  
for ex:                   123                               JOHN.SMITH                              JOHN.SMITH@GOLDMAN.COM

Do you have a suggestion as to how I could ultimately have a user enter just a person's name before a
static value "@GOLDMAN value" into the field EMAIL ADDRESS PREFIX, which in the example above would be JOHN.SMITH and then I could have another field, named, for example, EMAIL ADDRESS which would contain the combination of the name the user entered (for ex: JOHN.SMITH) into the field EMAIL ADDRESS PREFIX plus the suffix @GOLDMAN.COM ?

My objective is to send emails to xxx@GOLDMAN.COM where xxx is the value in EMAIL ADDRESS PREFIX.
I did not want the user to have to enter the static value @GOLDMAN.COM at the end of each value for the field
EMAIL ADDRESS PREFIX. However, when I execute my Email address routine, I wanted to retrrieve the value as
xxx.@GOLDMAN.COM  

I realize that I could have my VBA email ACCEES routine concatenate the value @GOLMAN.COM to the end of each value for
EMAIL ADDRESS PREFIX but I was wondering if there is an alternative to save the value input by the user in 1 field named
EMAIL ADDRESS PREFIX and then have another field named EMAIL ADDRESS contain the EMAIL ADDRESS PREFIX plus the value "@GOLDMAN.COM".
I realize that this is not efficient but is there a way to do this ?

   
0
zimmer9
Asked:
zimmer9
2 Solutions
 
dduserCommented:
Insert into YourTable(BranchNumber,Email_Address_Prefix,Email_Address) values (vAL1,VAL2,VAL3 + '@GOLDMAN.COM')

Regards,

dduser
0
 
Gautham JanardhanCommented:
select Email_Address_Prefix + Email_Address from urtable

check if access has a default value option for column if so u can specify

'@GOLDMAN.COM' while creating the table
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

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