On Wed, Dec 16, 2015 at 6:14 AM, Wilson, Jonathan <piercing_male@xxxxxxxxxxx
wrote:



Well that was far easier than I had assumed... but leads me on to one
final question.

Given the 10 digit ISBN holds a country code within it, and there is no
indication of how many digits make up the country code... how would I do
something along the lines of:

select SomeFields from BiblFile join with Countryfile where
BiblFile.ISBN contains partial match with CountryFile.Country.

So
011700001X TitleA
810115400X TitleB
922241012X TitleC
922941011X TitleD

and
0 English
1 English
80 Czech Republic
81 India
82 Norway
9229 Guatemala

creates
011700001X TitleA 0 English
810115400X TitleB 1 India
922241012X TitleC
922941011X TitleD 9229 Guatemala

Using your assumption of varying length fields, no trailing spaces.

I get the feeling that its something to do with joining the country file
to the bibliographic file, but in reverse - kind of.

Select SomeFields from BiblFile and CountryFile where rightjoin
(CountryFile.Country *cat '%') like Biblfile.ISBN


​Close, I think this should work..

Select SomeFields
from BiblFile
​join ​
CountryFile
​on Biblfle.ISBN like ​
(CountryFile.Country *cat '%')


​Charles​

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].