I am wanting to 'DROP Constraint' on a table by using the 'Alter Table' in vb code, this works fine if the field is the primary key, but if it's not it errors with 'CHECK constraint 'fieldname' does not exist'. Is there a way of using lookup to find if primary key exists before I try and drop it ?
in anticpation.
in anticpation.