Skip to Content
0
Former Member
Nov 28, 2006 at 03:15 PM

waht is the best way to comapre 2 fields in a select statement

35 Views

I am using a select statment to pull data back but the 2 fields that I compare are of differnt lengths and just the last 8 characters should match. I tried using an offset but it won't work in the select statement. Basically here is what I want to do but can't

loop at data into table2

select * from table1 where

field(4)+8 = table2-field

modify data from table2