Concat Using

Apr 6, 2007

I have a table:
id date status
====================
1 03/01/2006 W
1 02/01/2006 L
1 01/01/2006 L
1 31/12/2005 W
...
2 03/01/2006 L
2 02/01/2006 L
2 01/01/2006 W
2 31/12/2005 W
...
3 03/01/2006 W
3 02/01/2006 W
3 01/01/2006 W
3 31/12/2005 W
...

What I want is to concat the field status showing the latest 5 results, like this:

id status
=========
1 WLLWL
2 LLWWL
3 WWWWW

I have tried to use concat, but i can't get the desired one. Any idea to do that?

Thanks!

View Replies


ADVERTISEMENT

Concat Fields

Nov 19, 2007

I have a TableA and one of the fields is FileName (filename1.mpg, filename2.mpg...).

On a Form, I have a box and I want there to have this string for the first row:
"/VIDEOS/filename1.mpg".

How can I do that? THANKS!

View 5 Replies View Related

Concat Two Int Columns Into One

Jul 17, 2007

I got a access SQL question.

Let's say we have two int columns, I want to get the results Column1 + Column2 in string format

i.e

Column1 - Column2
5 - 2
6 - 2.5
10 - 6.5
10.5 - 8


I need to return the data as new column like:

NewColumn
"5 to 2"
"6 to 2.5"

so on

SQL + operator only works for string operation, how would I use it for numeric data type.

Thanks a bunch
shazaduh

View 2 Replies View Related

Last Name / First Name Concat Field

Jun 5, 2013

I am having trouble concatenating a field from an employee table where the format is "Last name, a comma, a space, first name." I attached a screen shot of my database.

View 2 Replies View Related

Slow Concat Function

May 2, 2008

Please see attached Sample,.

This may look like its fairly quick,.. but its the slow as hell,.. across the network "front end back end" especially when cross referencing againts qty's already ordered. "not included in sample"

I have only attached a basic sample of the query with some data, on my full system this acts very much like a Dlookup would do on a continuous form. "if you were foolish enough to use one there"

Check out the module for the code

My Question is: Is there an alternate "Speedy way" to produce the same results as seen in the sample.


To explain more,.. this is what i have and works fine,..."except having to wait a minute for the concat" which as you can imagine is very irritating for the user,.. when they have many lines to purchase.

When a job is created item required to be purchased are put in the Requests Table

Code:Tbl_03_RequestsID #Part NumberDescription StatusQty ReqUOMPriorityReq #Work Order1114N4082-6Leading Edge SkinStock Required1eaPriority 1WO07-421

Often the same part is Required on a different job,.

Code:Tbl_03_RequestsID #Part NumberDescription StatusQty ReqUOMPriorityReq #Work Order50114N4082-6Leading Edge SkinStock Required1eaPriority 1WO07-690

A query then creates a list to purchase

Code:ID #Part NumberDescription StatusQty ReqUOMWork Order1-50114N4082-6Leading Edge SkinStock Required2eaWO07-421 - WO07-690
The ID is then purchased against on the Order Screen

The Id goes into the purchase order table

The Id is then Split back down to its original numbers

The original numbers then look back at the Request table and update the status to Ordered

Code:Tbl_03_RequestsID #Part NumberDescription StatusQty ReqUOMPriorityReq #Work Order1114N4082-6Leading Edge SkinOrdered1eaPriority 1WO07-421


Code:Tbl_03_RequestsID #Part NumberDescription StatusQty ReqUOMPriorityReq #Work Order50114N4082-6Leading Edge SkinOrdered1eaPriority 1WO07-690

And so on,. When the unit is received it changes the status to received.

I can't do this with a temp table,.. that will take a bit of explaining so please take my experiance and word on that.

Sorry about the Table Formatting,... Is there another logical way to do this.

View 5 Replies View Related

Modules & VBA :: Add Currency Format To Concat String

Jan 20, 2015

I have a Concatenate string of text and currency. When joined together, the currency format disappears. I need to reformat so the string stays together with new format. Below is what I have:

Public Function ConcatAgreementFundsCommitted(ID As String) As String
'/ Purpose: Generate a concatenated string of Tracks for selected line.
On Error GoTo Err_Handler
Dim lngLen As Long 'Length of string.
Dim strOut As String 'Output string to concatenate to.

[code]....

I need 'Funds_Committed' to display as currency.

View 2 Replies View Related

General :: Concat Fields And Insert Text

Nov 6, 2014

In Excel I can do the following;

Field A Field B Result
Chips Fries Replacement of 'Chips' with 'Fries' on menu.
(null) Fries Addition of 'Fries' on menu.
Chips (null) Deletion of 'Chips' on menu.

Can I do this in Access using some form of append query?

View 5 Replies View Related

Modules & VBA :: Update A Column With Its Last Value And Concat To Value Of Another Column

Apr 16, 2015

DoCmd.RunSQL (" update tbl_userinformation SET [05-Henrichpiramid] = Yes where Username= Text146.value AND actualdate=Text148.value ;")
DoCmd.RunSQL (" update tbl_userinformation SET [combination] = [05-Henrichpiramid] where Username= Text146.value AND actualdate=Text148.value ;")

i want to update the column combination to its last value with concatanation to the value of current column.

View 11 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved