how truncate one table so i can make a relationship with another

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have several tables that are linked with a common field, but one particular
table needs formatting to make a relationship possible.eg

table order number shows as AD123.1 (table1)the other table AD1230000( table
2). I am looking for an expression to truncate both tables to have a field
in each showing orders as AD123 to enable the linkage

thanks Andy
 
It looks like LEFT([yourkey],5) should do it.

You could create two queries to pre-select and massage the data with :
shortkey: LEFT([yourkey],5)

and use these as inputs to the queries that you wish to run.
 
I have several tables that are linked with a common field, but one particular
table needs formatting to make a relationship possible.eg

table order number shows as AD123.1 (table1)the other table AD1230000( table
2). I am looking for an expression to truncate both tables to have a field
in each showing orders as AD123 to enable the linkage

thanks Andy

I'd VERY strongly suggest splitting this field into two in table
design view. Fields should be atomic; it appears that the Order number
consists of two parts, each with its own life - the AD123 and the rest
(1 or 0000 depending on the table).

Note that a Primary Key, and a table join, can consist of two (or ten
for that matter) fields, and that you can concatenate them for display
purposes.

John W. Vinson[MVP]
 
Back
Top