Hi,
I am running a very simple insert query in order to insert a record to a table named as "mytable". Here is the design view:
FieldName DataType Reqired DefaultValue
Tap_Name Text No
Max_number Long Integer No 0
Here is my...
Great thanks go to PHV, actually I modified your query a bit like this and it works now!
SELECT A.ID, A.Version, A.Action, A.Name
FROM Mytable A
WHERE A.Version = (SELECT Max(B.Version) FROM Mytable B WHERE B.ID=A.ID AND Nz(A.Action )<> "Deletion");
And I also really appreciate traingamer’s...
Dear PHV:
The result returns two records, Data1 with its version 2, which it should NOT be displayed since it is marked as “Deletion” in version 3. The other returned record is correct: Data2 with latest version 2. But your query did not return Data3 with its version 1 as I expected, even its...
First of all, I have to say, I do have a primary key in the table which is set to auto number; secondly, my table doesn't look like a normalized one because I only do insert or update in this application, even the action is marked as “Deletion”, it still has to be stored in the able, sort of...
I am trying to write a query to retrieve records that contain the latest (maximum) version number and action can’t be “Deletion”.
Sample table is listed below named as Mytable:
ID Version Action Name
1 1 Data1
2...
Hi,
I tried to write a query seems pretty simple, but it did not work properly. I have a text field in an Access table; its format combines letters with digits, something like this: SSID-1, SSID-12334. Each time when inserting record into this table, I need to judge the maximum digit in the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.