mak345
asked on
Application.Match with 2 Dimenstional Array
I am using VBA in MS Excel 2010 and SQL Server 2008.
I have a scenario where I am filling out a spreadsheet from a data file that has 2 columns.
I then create a recordset from a SQL 2008 db that contains 4 fields, 2 of which I want to compare to the data filled out from above.
I have done this before with 1 variable by running a loop on the SQL recordset and attempting to find the value with Application.Match.
How do I do this with 2 variables? I want to see if there is a line with both variables in the same record in my SQL table.
Thanks
I have a scenario where I am filling out a spreadsheet from a data file that has 2 columns.
I then create a recordset from a SQL 2008 db that contains 4 fields, 2 of which I want to compare to the data filled out from above.
I have done this before with 1 variable by running a loop on the SQL recordset and attempting to find the value with Application.Match.
How do I do this with 2 variables? I want to see if there is a line with both variables in the same record in my SQL table.
Thanks
ASKER
Thanks Matt,
Can you help me with the syntax?
If [COUNTIFS(DATA!A:A,mySQL!P ort,DATA!C :C,mySQL!A cc))] = 0 Then
do something
END IF
Can you help me with the syntax?
If [COUNTIFS(DATA!A:A,mySQL!P
do something
END IF
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
THANK YOU!!
Matt