Hi,

When using the following SQL query I get back just over 12,000 records.

SELECT JobNumber FROM myTABLE;

There are alot of duplicates within the records. I am wanting to only get back one of each JobNumber.

If I use SELECT JobNumber FROM myTABLE GROUP BY JobNumber the number of records is -1

This is within my VB Code.

Any ideas

try to use

SELECT distinct JobNumber FROM myTABLE;

try this:
SELECT distinct(JobNumber) FROM myTABLE;

Hi,

When using the following SQL query I get back just over 12,000 records.

SELECT JobNumber FROM myTABLE;

There are alot of duplicates within the records. I am wanting to only get back one of each JobNumber.

If I use SELECT JobNumber FROM myTABLE GROUP BY JobNumber the number of records is -1

This is within my VB Code.

Any ideas

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.