hello,
I have a table with following structure and data
field1 field2 field3
----- ----- -----
A B 1
A B 2
X Y 1
P Q 3
P Q 4
and the Output required is
field1 field2 field3
----- ----- -----
A B 1,2
X Y 1
P Q 3,4
Query please... ?
hello,
I have a table with following structure and data
field1 field2 field3
----- ----- -----
A B 1
A B 2
X Y 1
P Q 3
P Q 4
and the Output required is
field1 field2 field3
----- ----- -----
A B 1,2
X Y 1
P Q 3,4
Query please... ?
Doubt query alone will do that. Could there be more than 2 associated records? Review: http://allenbrowne.com/func-concat.html
Last edited by June7; 02-03-2014 at 12:10 AM.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
dear jun7,
thanks a lot for the reply
well can i get the following output ?
field1 field2 field3
----- ----- -----
A B 1
A B 2
P Q 3
P Q 4
only those records where field1 and field2 both values are same ?
this only will be sufficient for me.
Try:
SELECT * FROM tablename WHERE DCount("*","tablename","field1='" & [field1] & "' AND field2='" & [field2] & "'")>1;
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Dear June7
thanks a lot![]()