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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dim db As Database Dim rs As Recor

Status
Not open for further replies.

setyna

MIS
Sep 25, 2003
7
US
Dim db As Database
Dim rs As Recordset
Dim strsql As String
strsql = " Select Hardware.test" & _
" From Hardware" & _
" WHERE (((Hardware.test) Is Not Null))"

The code above produces an error message runtime error 13 type mismatch....Can someone help??
 
Hi

Try qualifying your declarations so

Dim db As DAO.Database
Dim rs As DAO.Recordset
Dim strsql As String
strsql = " Select Hardware.test" & _
" From Hardware" & _
" WHERE (((Hardware.test) Is Not Null))"

if you still have a problem it would help to know on which line it stops

Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Thanks..it's working now. I had a missing ref!!
My real objective for this sql is to find a number in my memo field...see below.

I am attempting to pull apart a string of data.
The piece I need is [Edit7]=19689421 and &[Edit7]=19449855485, but the issue is that is it is not always the same length

Examples:
[Edit1]=49&[Edit2]=4417-1281-1228-3138&[Edit3]=4pg&[Edit6]=94h&[Edit7]=19689421&[Edit8]=09/03/2003 08:00am&
[Edit1]=21&[Edit2]=4417658994525489&[Edit3]=4pg&[Edit6]=abc&[Edit7]=19449855485&[Edit8]=09/03/2003 08:00am&

enviroment- access 2000
field type-Memo
 
Thanks... I got it to work..New problem. It locate the first matching criteria then exit the function..I need it to loop thru the entire memo record and return all..Any thoughts??
 
HI

So look up Do Until in help

Consider using something like a Do Until Inst(1,x,y) = 0

where X and y are the things you are looking for and in


Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top