Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 7864 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

hello

i have a piece of software that contains a lot of data which i bring into filemaker. The problem is that i need to tell the software through a quickey to look up the next value. i am not sure how to make a field in filemaker that will;

get the next value of the alphabet in other words i need it to calculate the following values , i am just not sure how to script it to go through the numbers and the alphabet.

a1,a2,a3,a4,a5,a6,a7,a8,a9,aa,ab,ac,ad,ae,af,ag,ah,ai,aj,ak,al,am,an,ao,ap,aq,ar,as,at,au,av,aw,ax,ay,az,b1,b2,b3 etc

So when filemaker reaches the last record from the other database of

'aa' it then takes the next value to be calculated in a field called 'lookupvalue' and using a quickey goes to the other application and would then paste in 'ab' . Can anyone help me understand how to either get the next value or calculate the next value in the series i have outlined above?

Thanks Very very much

Dave

Posted

Hello Dave,

If the current alphanumeric value (eg 'aj') is in a text field in FileMaker called 'CurrentAlpha', you will be able to calculate the next alphanumeric value (ie 'ak') according to the schema you outlined in your post, using the following formula:

Middle("0123456789abcdefghijklmnopqrstuvwxyz", Int(Mod(((Position("0123456789abcdefghijklmnopqrstuvwxyz", Left(CurrentAlpha, 1), 1, 1) - 1) * 36) + (Position("0123456789abcdefghijklmnopqrstuvwxyz", Right(CurrentAlpha, 1), 1, 1)), 36^2)/36^1) + 1, 1) & Middle("0123456789abcdefghijklmnopqrstuvwxyz", Int(Mod(((Position("0123456789abcdefghijklmnopqrstuvwxyz", Left(CurrentAlpha, 1), 1, 1) - 1) * 36) + (Position("0123456789abcdefghijklmnopqrstuvwxyz", Right(CurrentAlpha, 1), 1, 1)), 36^1)/36^0) + 1, 1)

Essentially this is a manipulation of base 36 numbering, and will produce up to 1295 unique sequential values from 01 to zz within the confines of the two digit limitation. wink.gif

This topic is 7864 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.