Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help with proper syntax on dcount with and

Status
Not open for further replies.

MightyRoo

Programmer
Jan 5, 2005
22
US
Would really appreciate some help with this and reasoning.....
Code:
'THIS WORKS (below)
     blah = DCount("[value_id]", "mage_catalog_product_entity_va[URL unfurl="true"]http://www.tek-tips.com/threadminder.cfm?pid=702rchar",[/URL] "[attribute_id] = " & [XAttributeID])
'THIS WORKS
     blah1 = DCount("[value_id]", "mage_catalog_product_entity_varchar", "[entity_id] = " & [entity_id])
'How do I make this work
     blah2 = DCount("[value_id]", "mage_catalog_product_entity_varchar", "[attribute_id] = " & [XAttributeID] And "[entity_id] = " & [entity_id])

Access generates a "Type Mismatch" Error 13
I have tried this multiple ways and just get different errors.
Thanks!
 
[attribute_id] = " & [XAttributeID] & " And [entity_id] = " & [entity_id]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top