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!

error using LEFT( ) expression 2

Status
Not open for further replies.

PenelopeC

Technical User
May 12, 2003
72
US
Hi,

I'm running Access97 on a Win2K Pro box.

I am trying to run a query in Access97 that retrieves the first three numbers of a field -- data format=text -- as a grouping level for a report based on the query. This worked before but I've recently had to f disk my hard drive and re-install everything...am I missing library or something??

Here's the syntax I'm using in the select query:

AU:Left([Company_Na],3)

That's right isn't it?! It worked before. Now it doesn't. Thanks in advance for any help/advice/whack-on-the-head-with-a-big-stick-because-I've-missed-something-stupid.




PenelopeC
~~~>-/O~~~~~swimming right along
 
Hi Penelope,

are you getting an error? Check the project's references to see if something is missing and if so restore it.
 
Yes, I should have put the error in the post...

I get all the data returned, except in the AU column (which I've named, see above) returns #Error.

So how would I check the projects references? I'm not sure I've got a handle on that.

And Thanks for responding!

PenelopeC
~~~>-/O~~~~~swimming right along
 
Open any code window and select Tools|References. Look for any that might be marked as MISSING. Most of the time you can simply uncheck the missing references. Some times you need to find an equivalent reference from the list on your PC.

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
Just to eliminate the obvious, try running
Code:
Select * From tbl Where Company_Na IS NULL
You will get errors if you attempt to do string manipulation on a field with a null value.
 
Oh Geez! The missing references were to Adobe Distiller drivers. I removed them and the problem went away.

Thanks so much!!



PenelopeC
~~~>-/O~~~~~swimming right along
 
PenelopeC,

TO check your references, in Access go to the Tools Menu, then Macros, Then Visual Basic Editor to start the vb Editor, then from there choose the Tools menu of the editor, and select references. the ones that are checked are the ones you are using. there should be on called Visual Basic for Applications. it is a reference to the file:
C:\Program Files\Common Files\Microsoft Shared\VBA\VBA6\VBE6.DLL
if this is not checked at the top of the list, look for it in the list elsewhere and check it off. If you don't find it there then click on browse and browse to the above file to add it to the list. I hope this somehow makes sense to you and good luck!

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top