dazedconfused
IS-IT--Management
I am designing a web page that selects data form a pervasive database ver 7
When I run this:
Ordsql = "SELECT * FROM equipment WHERE contractnumber LIKE '000000000000016' "
It works, but when I try to use a variable sent form another page:
Ordsql = "SELECT * FROM equipment WHERE contractnumber =" & Request ("var")
I get this:
[Pervasive][ODBC Client Interface][LNA][Pervasive][ODBC Engine Interface]Incompatible types in predicate.
When I try to replace = with LIKE, I get this:
[Pervasive][ODBC Client Interface][LNA][Pervasive][ODBC Engine Interface]Syntax Error: SELECT * FROM equipment WHERE contractnumber LIKE00000000000020<< ??? >>4
I have done this on other pages aith this database and got it to work but I always used =.
Can anyone point me the right direction?
When I run this:
Ordsql = "SELECT * FROM equipment WHERE contractnumber LIKE '000000000000016' "
It works, but when I try to use a variable sent form another page:
Ordsql = "SELECT * FROM equipment WHERE contractnumber =" & Request ("var")
I get this:
[Pervasive][ODBC Client Interface][LNA][Pervasive][ODBC Engine Interface]Incompatible types in predicate.
When I try to replace = with LIKE, I get this:
[Pervasive][ODBC Client Interface][LNA][Pervasive][ODBC Engine Interface]Syntax Error: SELECT * FROM equipment WHERE contractnumber LIKE00000000000020<< ??? >>4
I have done this on other pages aith this database and got it to work but I always used =.
Can anyone point me the right direction?