<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=968481418-14042003><FONT face=Arial color=#0000ff size=2>This
is an invoice date which is going to be different each time the process is
run.</FONT></SPAN></DIV>
<DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B> Don Elliker
[mailto:delliker@hotmail.com]<BR><B>Sent:</B> Monday, April 14, 2003 11:59
AM<BR><B>To:</B> accessd@databaseadvisors.com<BR><B>Subject:</B> RE: [AccessD]
Search for string with wildcard characters<BR><BR></FONT></DIV>
<DIV>
<DIV>
<P>The date changes from what to what? Is it incremental in any way? If yes,
then a loop oughta do it. Otherwise if it stays the same, what is the purpose of
the search? Hope I'm not being dense.</P>
<P>_d<BR>"Things are only free to the extent that you don't pay for them."
</P></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>>From: rusty.hammond@cpiqpc.com
<DIV></DIV>>Reply-To: accessd@databaseadvisors.com
<DIV></DIV>>To: accessd@databaseadvisors.com
<DIV></DIV>>Subject: RE: [AccessD] Search for string with wildcard characters
<DIV></DIV>>Date: Mon, 14 Apr 2003 11:00:19 -0500
<DIV></DIV>>
<DIV></DIV>>I think if there was a way to incorporate the Like operator with
the InStr
<DIV></DIV>>function then my problem would be solved.
<DIV></DIV>>
<DIV></DIV>>Let me explain what I'm doing and maybe someone will have
suggestion for a
<DIV></DIV>>better way of doing it.
<DIV></DIV>>
<DIV></DIV>>My client sends a text file of invoices to a Railroad (RR)
company. This RR
<DIV></DIV>>requires a specific file format for their billing system to
import the
<DIV></DIV>>invoices. My client has tried working with their accounting
software people
<DIV></DIV>>to get the format they need but they say they have done what they
need to do
<DIV></DIV>>so if it requires more coding they will do at a fee of $250 per
hour and
<DIV></DIV>>quoted 25 hours (great money if you can get it).
<DIV></DIV>>
<DIV></DIV>>Anyway, I'm taking the text file the accounting software creates
which is
<DIV></DIV>>close to what is needed, and making the few more changes to it to
make it
<DIV></DIV>>compatible with the RR company. So far, I've discoved that by
searching the
<DIV></DIV>>file for certain strings, I can replace that string with
something else.
<DIV></DIV>>It's been fairly simple up to this point since the strings I'm
searching for
<DIV></DIV>>have all been static. I'm storing the strings to search for and
replace
<DIV></DIV>>with in a table so if something changes they just adjust the
strings in the
<DIV></DIV>>table and away we go.
<DIV></DIV>>
<DIV></DIV>>Now we have a change where the portion of the file I need to
change includes
<DIV></DIV>>a date which changes with each new file. Now, I could have the
client
<DIV></DIV>>change the date in the searchfor string each time they run the
program for a
<DIV></DIV>>new file but it would be really nice if I could have a function
search for
<DIV></DIV>>"N1~GA~????????" (where the ?'s represent a date in yyyymmdd
format)in this
<DIV></DIV>>string "REF~03~!N1~GA~20020414" and return a 9.
<DIV></DIV>>
<DIV></DIV>>Clear as mud?
<DIV></DIV>>
<DIV></DIV>>Rusty
<DIV></DIV>>
<DIV></DIV>>-----Original Message-----
<DIV></DIV>>From: Mike and Doris Manning [mailto:mikedorism@ntelos.net]
<DIV></DIV>>Sent: Monday, April 14, 2003 10:20 AM
<DIV></DIV>>To: accessd@databaseadvisors.com
<DIV></DIV>>Subject: RE: [AccessD] Search for string with wildcard characters
<DIV></DIV>>
<DIV></DIV>>
<DIV></DIV>>How about InStr function?
<DIV></DIV>>
<DIV></DIV>>Doris Manning
<DIV></DIV>>Database Administrator
<DIV></DIV>>Hargrove Inc.
<DIV></DIV>>www.hargroveinc.com
<DIV></DIV>>
<DIV></DIV>>
<DIV></DIV>>-----Original Message-----
<DIV></DIV>>From: accessd-bounces@databaseadvisors.com
<DIV></DIV>>[mailto:accessd-bounces@databaseadvisors.com] On Behalf Of
<DIV></DIV>>rusty.hammond@cpiqpc.com
<DIV></DIV>>Sent: Monday, April 14, 2003 10:57 AM
<DIV></DIV>>To: accessd@databaseadvisors.com
<DIV></DIV>>Subject: [AccessD] Search for string with wildcard characters
<DIV></DIV>>
<DIV></DIV>>
<DIV></DIV>>Does anyone have any code that will search a string variable for
a string
<DIV></DIV>>that includes wildcard characters and returns the location?
<DIV></DIV>>
<DIV></DIV>>ie
<DIV></DIV>>strVariable="This is a test"
<DIV></DIV>>search strVariable for "te??" returns 11
<DIV></DIV>>
<DIV></DIV>>
<DIV></DIV>>Rusty
<DIV></DIV>>
<DIV></DIV>>_______________________________________________
<DIV></DIV>>AccessD mailing list
<DIV></DIV>>AccessD@databaseadvisors.com
<DIV></DIV>>http://databaseadvisors.com/mailman/listinfo/accessd
<DIV></DIV>>Website: http://www.databaseadvisors.com
<DIV></DIV>>
<DIV></DIV>>_______________________________________________
<DIV></DIV>>AccessD mailing list
<DIV></DIV>>AccessD@databaseadvisors.com
<DIV></DIV>>http://databaseadvisors.com/mailman/listinfo/accessd
<DIV></DIV>>Website: http://www.databaseadvisors.com
<DIV></DIV>>_______________________________________________
<DIV></DIV>>AccessD mailing list
<DIV></DIV>>AccessD@databaseadvisors.com
<DIV></DIV>>http://databaseadvisors.com/mailman/listinfo/accessd
<DIV></DIV>>Website: http://www.databaseadvisors.com
<DIV></DIV></DIV><BR clear=all>
<HR>
MSN 8 helps <A href="http://g.msn.com/8HMLENUS/2743">ELIMINATE E-MAIL VIRUSES.
</A>Get 2 months FREE*. </BODY></HTML>