473,387 Members | 1,464 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,387 software developers and data experts.

Database query, part of records

Hello!
I have some records in a database (access), like this:

001111-10
001111-11
001111-12
002222-10
002222-11
002222-12

I need to retrive the first record of each sequence, "001111-10" and
"002222-10" in the example above.

Next part is I need to show only the first part of each record,
"001111" and "002222" on an Active Server Page (ASP).

Help with any part of this would be appreciated.

BR/Peter
Nov 13 '05 #1
2 1251
On 30 Aug 2004 13:06:33 -0700, pe***@topcom.nu (Peter) wrote:
Hello!
I have some records in a database (access), like this:

001111-10
001111-11
001111-12
002222-10
002222-11
002222-12

I need to retrive the first record of each sequence, "001111-10" and
"002222-10" in the example above.

Next part is I need to show only the first part of each record,
"001111" and "002222" on an Active Server Page (ASP).

Help with any part of this would be appreciated.


It's an ASP question, but you didn't post to any ASP groups. In fact,
you hit only groups where this would be off topic. Try posting to
microsoft.public.inetserver.asp.db

Jeff
Nov 13 '05 #2
pe***@topcom.nu (Peter) wrote in message news:<f6*************************@posting.google.c om>...
Hello!
I have some records in a database (access), like this:

001111-10
001111-11
001111-12
002222-10
002222-11
002222-12

I need to retrive the first record of each sequence, "001111-10" and
"002222-10" in the example above.
SELECT Left$([Recno],6) AS SeqNo, First(Table1.RecNo) AS FirstOfRecNo
FROM Table1
GROUP BY Left$([Recno],6);
Next part is I need to show only the first part of each record,
"001111" and "002222" on an Active Server Page (ASP).
SELECT Left$([Recno],6) AS SeqNo
FROM Table1
GROUP BY Left$([Recno],6);

Help with any part of this would be appreciated.

BR/Peter

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Rich N | last post by:
I want to move several records from one table to a new table. My database is set up so that there's the "regular" database, and the ".be" database. In which do I use the Make Table Query?
5
by: Bec | last post by:
I'm in desperate need of your help.. I need to build an access database and have NO idea how to do this.. Not even where to start.. It IS for school, and am not asking anyone to do my...
4
by: cover | last post by:
I have two distinctively different pieces of equipment that I'm trying to build a database for, each having 20 inputs which makes my mysql table 40 fields wide. Form one is for 'shakers' and...
29
by: MP | last post by:
Greets, context: vb6/ado/.mdb/jet 4.0 (no access)/sql beginning learner, first database, planning stages (I think the underlying question here is whether to normalize or not to normalize this...
2
by: Allen Anderson | last post by:
Hi, I'm trying to design contact (names and addresses) tables in an Access database. Some of the contacts represent vendors, some are board members of the organization, some are donors, some...
10
by: Jim Devenish | last post by:
I have a split front end/back end system. However I create a number of local tables to carry out certain operations. There is a tendency for the front end to bloat so I have set 'compact on...
4
by: jonniethecodeprince | last post by:
Greetings all. I have a problem with PERL and SQL Server. I need to upload a database query to a web page using PERL and SQL Server. I have tried to do this myself but nothing displays on the...
1
by: hr833 | last post by:
hi.. i'm using a append query to filter some new records that must be updated in the lookup table. In this lookup table it consist of the part number and the type of the product. the part number...
9
by: =?Utf-8?B?TUNN?= | last post by:
I'm sure the answer to my question varies depending on the situation, but I am looking for a general "best practice". If I have an asp.net application and I load certain data from a database,...
7
by: bhipwell via AccessMonster.com | last post by:
Hello, I have developed an employee benefits database that currently contains over 3000 employees and 70+ companies. Having started the database as a really simple solution for our clients, the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...

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.