We help IT Professionals succeed at work.
Get Started

Forgotten old syntax

Mike Littlewood
Last Modified: 2010-08-05

Hi all,

Could someone remind me of some syntax please, Im pretty sure you can do this but let me know if I can't.

I have 2 tables, one is a local Paradox table on my PC, one is an SQL Server on the network.

The paradox one has 2 fields, Quantity and Code
The SQL Server one has 2 fields, ID and Code

What I want to do is select the sum of the quantities from the paradox table based on the list of codes from the SQL Server table.

If it was 2 SQL Sever tables the SQL Text of my TQuery would be nice and easy like this

SELECT Sum( Quantity) AS TotalQuantity
FROM Table1
WHERE Code in
  FROM Table2

What I currently have is

SELECT Sum( Quantity) AS TotalQuantity
FROM "ParadoxTable.db"
WHERE Code in
  FROM SQLServerTable

but it is complaining about the syntax of the statement.
Is this possible, and if so can someone correct the syntax.
Been SOOOO long since I had to touch paradox.
Watch Question
Top Expert 2004
This problem has been solved!
Unlock 1 Answer and 2 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE