Avatar of Gary Croxford
Gary CroxfordFlag for United Kingdom of Great Britain and Northern Ireland

asked on 

MS Access Query Invalid Procedure Call InStr([xxx],"y")-1

Thank you for looking at my question,

I am querying a table in access that has a text field containing data strings of varying lengths.
I am trying to separate out the first part of the string - nominally the first 16 to 19 characters followed by a semi-colon.

To achieve this I have tried the following:

ItemName: Left([Description],InStr([Description,":")-1)
and
ItemName: Left([Description],(InStr([Description,":")-1))

but both return an invalid procedure call message.

ItemName: Left([Description], InStr([Description,":"))
returns the string I need and the semi-colon

What have I missed?
SQL

Avatar of undefined
Last Comment
Gary Croxford
ASKER CERTIFIED SOLUTION
Avatar of smilitaru
smilitaru
Flag of Romania image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Gary Croxford
Gary Croxford
Flag of United Kingdom of Great Britain and Northern Ireland image

ASKER

Thank you for your help
SQL
SQL

SQL (Structured Query Language) is designed to be used in conjunction with relational database products as of a means of working with sets of data. SQL consists of data definition, data manipulation, and procedural elements. Its scope includes data insert, query, update and delete, schema creation and modification, and data access control.

61K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo