Semicolon delimited text query help

  • Thread starter Thread starter Al Guerra
  • Start date Start date
A

Al Guerra

I did not design this. I have two tables, table A has a field "Link"
that is of type string and contains a unique 30 character string (700
hundred of them). Table B contains a unique 28 character identifier,
and a field that contains multiple 30 character unique identifers
(from table A) that are separated by a "semi-colon" in a field called
A_Links. How do I select all from table B that contains a unique
identifer from table A? As a separate record? Table B will have maybe
10-15 of the unique identifiers from table A. I would get lots of
records from table B that contain the same Table A unique field.

THANKS for any help!!!
 
Possible solution:

SELECT tblB.IDField, tblA.LinkField
FROM tblA, tblB
WHERE tblB.MultiLinks Like "*" & tblA.LinkField & "*"

HTH
Van T. Dinh
MVP (Access)
 
Thanks, I will try that ,,, I have:

Table A:
GUID : system:string ' unique 30 character string
item 1 : system:string ' 7 characters
item 2 : system:string ' 5 characters
item 3 : system:string ' 15 characters'
item 4 : system:string ' 9 characters
item 5 : system:string ' 5 characters
item 700 : system :string : 10 characters

Table B:
GUID : system:string ' unique 28 character string
item 1 : system:string ' 7 characters
item 2 : system:string ' 5 characters
item 3 : system:string ' 15 characters'
item 6 : system:string ' 9 characters
item 7 : system:string ' 30 characters, unique GUIDs (1-30) from
table A separated by a ";"
item 33700 : system :string : 10 characters

For example, a table b.GUID35.item7 has TABLE A.GUID23; TABLE
A.GUID43;TABLE A.GUID46;TABLE A.GUID54;
a table b.GUID36.item7 has TABLE A.GUID13; TABLE A.GUID44;TABLE
A.GUID56;TABLE A.GUID64;....20 GUIDs
a table b.GUID37.item7 has TABLE A.GUID323; TABLE A.GUID43;TABLE
A.GUID46;TABLE A.GUID54;.....34 GUIDs
a table b.GUID5543.item7 has TABLE A.GUID487; TABLE A.GUID43; TABLE
A.GUID46;TABLE A.GUID54; ....15 GUIDs
a table b.GUID4466.item7 has TABLE A.GUID529; TABLE A.GUID43;TABLE
A.GUID46;TABLE A.GUID54; .....5 GUIDs

I want to query the two tables, and return for every GUIDxxx in Table
B.item 7 the table A.item 2, Table A.item3, table A.item6.
I could use the tableb.item2.item3 as the criteria to return only a
small number (maybe 50-200 for a specific combo) from the table A.

I hope this helps. I did not design this, and question why they
choose to use system:string as the types for all entries, and use
semi-colons to separate the entries. BUT I need to work with this.
Sorry to be so vague about the names, etc but I must because of what
it is...

THANKS for your help, I could not find any reference to semi-colon
delimiters to store/retrieve data in a lot of books at the various
bookstores, nor online!
 
Sorry, I am not following your example but if it is a list, you will need to
use Like or Instr().
 
Back
Top