A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

VBA can't bring back Like '*active*' records



 
 
Thread Tools Display Modes
  #1  
Old March 9th, 2006, 03:25 PM posted to microsoft.public.access.forms
external usenet poster
 
Posts: n/a
Default VBA can't bring back Like '*active*' records

Does anyone know how to bring filter a SQL using LIKE '*active*'

SQLString = "SELECT downloads.Branch_Number, downloads.msglog_text,
downloads.item_id, downloads.msglog_crtdt "

SQLString = SQLString & "FROM downloads "

SQLString = SQLString & "WHERE (((downloads.Branch_Number)= " &
rst!Branch_Number & ") AND ((downloads.msglog_text) Like '*active*')
AND ((downloads.item_id)= " & rst!item_id & ")) "

SQLString = SQLString & "ORDER BY downloads.msglog_crtdt;"

  #2  
Old March 9th, 2006, 05:21 PM posted to microsoft.public.access.forms
external usenet poster
 
Posts: n/a
Default VBA can't bring back Like '*active*' records

On 9 Mar 2006 07:25:37 -0800, "
wrote:

Does anyone know how to bring filter a SQL using LIKE '*active*'

SQLString = "SELECT downloads.Branch_Number, downloads.msglog_text,
downloads.item_id, downloads.msglog_crtdt "

SQLString = SQLString & "FROM downloads "

SQLString = SQLString & "WHERE (((downloads.Branch_Number)= " &
rst!Branch_Number & ") AND ((downloads.msglog_text) Like '*active*')
AND ((downloads.item_id)= " & rst!item_id & ")) "

SQLString = SQLString & "ORDER BY downloads.msglog_crtdt;"


If there is a Text field named msglog_text (*NOT* a Lookup field,
which will contain a concealed ID number) in the Downloads table this
should work. What is happening? What error (if any) are you getting?
Do you get anything if you use

LIKE '*'

as the criterion?

John W. Vinson[MVP]
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Is there a way to bring back a document that hasn't been saved helpmeplease New Users 1 October 21st, 2005 05:22 AM
Attn Sprinks- Not duplicate insert records babs Using Forms 1 December 13th, 2004 06:25 PM
Bring back NetFolders for Outlook so I can synch with other users. NetFolders fan Contacts 1 November 17th, 2004 02:10 PM
having access reference 2 records and come back with a specified value in another record Beth Baar General Discussion 0 September 8th, 2004 09:17 PM


All times are GMT +1. The time now is 09:51 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.