473,404 Members | 2,178 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

Combine Rows and create fields

I have a access table that contains multiple reccords per client. I want to combine each record based on the client into one row with separate field names.

Table below:

JobNbr, LineNbr, Desc, Product, Brand
1, 1, BAR, Mark5, Barcode
1, 2, SPR, Mark2, Sprint
1, 3, SPI,Mark4,Roll
2,1,BAR,Mark1, Barcode
2,2,SPR,Mark3,Valet
3,1,TAG,Mark7,Valet

Results:

JobNbr,LineNbr,Desc, Product, Brand, LineNbr2, Desc2, Product2, Brand2
1,1,Bar,Mark5,Barcode,2,SPR,Mark2,Sprint,3,SPI, Mark4,Roll
2,1,Bar,Mark1,Barcode,2,SPR,Mark3,Valet
3,1,Tag,Mark7,Valet

Thanks
Carlos
Oct 4 '07 #1
7 1640
NeoPa
32,556 Expert Mod 16PB
Pretty well impossible I'm afraid Carlos.
The closest thing I can think of to this (not an exact match) is Producing a List from Multiple Records
Oct 5 '07 #2
How could I get this to work if I had more that two columns?
Oct 9 '07 #3
NeoPa
32,556 Expert Mod 16PB
How could I get this to work if I had more that two columns?
The way you're looking to do it (from 1st post) would involve creating a formatted text field of the other fields and passing the resultant string into the function.
You would be better off using a different character to separate the fields than the function uses to separate the records though or it could be confusing.
Oct 9 '07 #4
The way you're looking to do it (from 1st post) would involve creating a formatted text field of the other fields and passing the resultant string into the function.
You would be better off using a different character to separate the fields than the function uses to separate the records though or it could be confusing.
Neo,
I'm refering to your reply in post 2. The solution you refered to in that post only has a table with two columns. I tried that and can't seem to get more than two columns combined.

Thanks
Carlos
Oct 9 '07 #5
NeoPa
32,556 Expert Mod 16PB
That's what I understood you to mean Carlos. That's why my answer reflects that. Have another read of it and if it still doesn't make sense to you then post back & I wiill try to fill in the details a bit more. It's very late for me now so I'm off to bed. I'll pick up any reply in the morning :)
Oct 10 '07 #6
I don't understand can you shed some light on your thoughts.
Oct 10 '07 #7
NeoPa
32,556 Expert Mod 16PB
I will try to do that for you Carlos but it may take a short while. I'm not around this evening either so, just in case I forget, bump this thread if you don't see anything from me by Friday.
Oct 10 '07 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Steve Jorgensen | last post by:
Hi all, I'm working on the schema for a database that must represent data about stock & bond funds over time. My connundrum is that, for any of several dimension fields, including the fund name...
8
by: mark | last post by:
Access2000 How do I write a query that combines the CTC field from each record below into one record? I need to concatenate the CTC field with a separator, like below: ...
1
by: snOOp | last post by:
I am trying to combine the data from two similar tables into one query, but I need for all of the records from both tables to show up and I want the ones that have matching 'emplid' to be combined...
14
by: imani_technology_spam | last post by:
I have the following table; CREATE TABLE ( IDENTITY (1, 1) NOT NULL , (7200) COLLATE SQL_Latin1_General_Pref_CP1_CI_AS NOT NULL , CONSTRAINT PRIMARY KEY CLUSTERED ( ,
5
by: hon123456 | last post by:
Dear all, I got a table with three rows like the following clientid name age location 1 peter 1 32 1 ...
8
by: cycleops | last post by:
Can anyone please help? I'm trying to combine 2 or more similar rows into one row, accumulating a field for quantity. E.g.: index, field1, field2, quantity 1, ccc, bbb, 5 2, ...
1
by: ktang3227 | last post by:
Hi all, I have a table which list all the different product# and quantity of the product in each row. But for some reason, some of the product splites into 2 rows. For example; Product A has...
2
denny1824
by: denny1824 | last post by:
Hi everyone, Here is my problem. I have a Table Variable (I could easily turn it into a Temp Table instead) that will sometimes have rows that are identical except for one specific column. The...
2
by: mzmatterafact | last post by:
I'm back and please be warned I'm a total NEWBIE, and i've had success with my previous post so I would like to buy another vowel! Now i have taken my csv file and imported to a DataTable, i've...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.