query help

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I need to extract data from the left side of a string where the seperator is
a carat ^ . I have looked into the help for the Mid function, but can't seem
to get it work properly. Suggestions please...
 
To get the string on the left to the ^
?left(FieldName,instr(FieldName,"^")-1)

To get the string on the right to the ^
?mid(FieldName,instr(FieldName,"^")+1)
 
I got it. The field name had a space in it so I enclosed it with brackets.
Thanks!
 
Brian,

can you help me with the mid functiuon.

I have a text here: "Predefined:Purchase Order:PURCH_1.0:43403-1:136"
I want to create a view on the SQL server to pull out only "43403" which is
the PO#. it started right after the _1.0: and it is always a 5 digit numbers.

Thanks,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top