-
How to do this....
I have met some trouble...... :(
a program insert some record to DB like this
ID,Num,Weight,Date,Signer....
, then print it together, I filter it by Date,SQL like this
SELECT * FROM shipment WHERE date BETWEEN '2003-10-10' AND '2003-10-11'
but my boss tell me: I need select ID by myself. so I have to filer it by ID, But the report need a lot of ID,how can I do? I must use the SQL like this??????
SELECT * FROM shipment WHERE ID = 1 or ID = 2 or ID = 3.....??
thanks......
:(
-
Re: How to do this....
Try something like this:
Select * from shipment where ID In (1,2,3,4)
-
if I have 100 or more record.........
-
select * from shipment where id between 1 and 100
-
Can I have an other way to do.
I think maybe I can create a temporary table to do .....