sql like statment in excel

  • Thread starter Thread starter Manual Labor
  • Start date Start date
M

Manual Labor

I need to do the following:

If cell on first sheet is equal to corresponding cell on second sheet AND
different cell on first sheet is greater than corresponding cell on second
sheet THEN another cell on first sheet is set to value from second sheet.

Is there any way to do sql in excel?

thanks
 
Hi Manual,

Would this work for you?:

=IF(AND(Sheet1!A1=Sheet2!A1,Sheet1!B1>Sheet2!B1),Sheet2!B1,"")

Put this formula into the cell you want to set the value of.

(obviously, the cell ref's are just examples)

Gabhan Berry
AI Prediction and Forecasting in Excel
http://www.pececillo.com
 
You can query a closed Excel workbook using SQL, ADO and the MS OLEDB
Provider for Jet. However, if the workbook is open (e.g. the active
workbook or the workbook containing the ADO code) you'll suffer with
the memory leak bug (MSDN Q319998).
 
Back
Top