6 Replies Latest reply on Feb 27, 2015 7:26 AM by disabled_Rob_2

    GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE

      Title

      GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE

      Post

      " GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE"

      How would you filter
      A Global List such as

      1 doors
      3 windows
      5 chairs
      1 rug
      10 lamps

      the items are listed in a global field along with their number of occurrences from a text field called TopicLetters.

      Wanting to sort these items from top to bottom high to low rearranged the list in my global field called unique words and their occurrence.

      i could simply create a new record throw them into a field that's indexed and sort them and grab them to put back into the global field then delete the new record.

      But was thinking maybe they can be sorted inside a variable some way using filter values. A filter expression that allowed me to dictate what to filter thus arrive at the sorting of .. GLOBAL FIELD ITEMS INSIDE A VARIABLE!!

      THANKSnADVANCE
      Robert

        • 1. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE
          raybaudi

          Which could be the highter number of a single item ? ( in your example is 10 )
          How many items could be into the global field ? ( in your example are 5 )

          • 2. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE
                                                             
                           
            _i_know why u ask. No _i_am not crazy about creating tables for resolving text parsing! Text parsing as u know, not only has really evolved but all the parsing going around is in a evolution a process of its very own for manipulating data and _i_ seriously believe its being used more so than the basic components of Filemaker’s engine, the alternative to parsing which is creating more tables, more fields more layouts.

                           Proper programming. requires expressions. formulas. that moves and analyzes data. expressions are built from. fields.script steps. functions and calculations. and most importantly layout features of FileMaker. such as tables. records. views. portals.

                           All these elements have to be considered. to arrive at building minimalistic expressions. Minimal steps. and it should be accomplished by not having to create multiple arrays of Tables, Relationships and numerous fields. Thus,this would require more text parsing expressions / formulas, for proper solutions that won’t crash from fragmentation of memory blocks. Parsing text expressions for manipulating data just keeps on evolving as we all know MUCH faster than FileMaker herself. expressions / formulas / calculations certainly replacees Layout views, more tables and forced to rely on numerous fields. that is where all programming ends up anyway. in the language in the scripting expressions of intelligence. for arriving at logistic computer results.

                           Here's the story:
                           YOU have a field:text: TopicPOSTletters. like this one herein.Instead of YOU having to read through all YOUR Post Letters to know at a quick glance what's going on (the main subject) YOU simply loop / run YOUR letter through a Word Processor:

                           YOU quickly want to eliminate all the trivial words like "our,to,this,and etc" so YOU employ CF Custom Functions such as uniqueWords(text ; minimumWordLength ; caseSensitive ; shouldSkipNumbers). which gives YOU ability to change the filter on the fly.

                           _i_ had it going: displaying in my global with variable loop, resulting a value list having on each line displaying: •number occurrence followed by unique words.

                           But lost how _i_ did it, when tearing it down trying to find more ways in my expression to actually sort all the unique words by their occurrence numbers by evolving the filtering process. This unique CF is giving duplicate words such as "elements and element" and “Parsing parsing” which is not considered unique.


                           BOTTOM LINE: FOR YOU TO KNOW ANYTHING WHATS GOING ON IN A QUICK GLANCE HEREIN YOU NEED:
                           -unique words.
                           -be able to filter them.
                           -show their number occurrence.
                           -sort them inside the global field — all done with inside variables, text parsing, filtering.

                           Wondering if can be done using recursive expressions?

                           Q-What's highest number of a single item you ask?

                           A- well let's say YOU want to save some brain cells - save time - you do not want to focus intense concentration, towards HAVING to read all details of Post / my post herein just in order to find out, The Main Attributes of whats the main subject — what's going on.. “so you instead run all my text words herein though YOUR “I.A.M Text Processor”.

                           -You get word count.
                           -unique words.
                           -be able to filter them.
                           -show their number occurrence.
                           -sort them inside the global field — high to low.

                           RESULTING THOSE WORDS HIGHEST IN NUMBER to show you more what's going on herein.

                           All in one moments quick flash, YOU now can decide to help me take action or better to wait as YOU run other Post through YOUR “I.A.M Text Processor” giving you ability to arrive at proper expressions.

                           The Main Subject Word The Highest occurrence number Word in an average letter like this one to you _i_say.. 10 at the most.

                           Q- YOUR question, How many items could be into the global field ? ( in your example are 5 )

                           Depends how well it can be filter. For specific unique words. Right now hers the OUTPUT:

                           •0 Attachments
                           •0 eMail addresses.
                           •0 web Addresses
                           •0 Telephone Numbers.
                           •0 Dates
                           •0 Numbers in text.
                           •30 Paragraphs.
                           •67 sentences.
                           •650 words in Topic Post
                           •291 words got processed.
                           •359 words filtered out.
                           •18-20 for highest number words thats because they are words like “YOU.”the” etc trivial words which have not been filterout yet.

                           SEVERAL WORDS of the 291 — so YOU see by looking quick glance at result below the Words •07 parsing and •07 Parsing is the Main Subject. and sub topics are:

                           •07 parsing
                           •10 text
                           •03 Processor
                           •05 tables
                           •09 expressions
                           •05 occurrence
                           •04 global
                           •04 filter
                           •04 Word
                           •04 main
                           •03 subject
                           •07 Parsing

                           Not Words: SQL; not boats; not Server; not Online; not girls; not food; no money issues etc. end

                           THANKSnADVANCE
                           Robert jesus Land Land Tidd
                           
            • 3. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE
              raybaudi

              I do not understand much of what you said ( I'm Italian ). BTW this calculation works for your first example.
              I think that you'll need to create a custom function or a looping script with my calc in mind.

              This returns:

              10 lamps
              5 chairs
              3 windows
              1 doors
              1 rug

              Let([
              T = YourTextField ;
              SN = FilterValues ( "20¶19¶18¶17¶16¶15¶14¶13¶12¶11¶10¶9¶8¶7¶6¶5¶4¶3¶2¶1" ; Filter ( T ; "1234567890¶" ) ) ; // sorted numbers
              VWD = Filter ( T ; KanjiNumeral ( T ) ) // values without digits
              ];
              FilterValues ( T ;
              GetValue ( SN  ; 1 )  & GetValue ( VWD ; 1 ) & ¶ & 
              GetValue ( SN  ; 1 )  & GetValue ( VWD ; 2 ) & ¶ & 
              GetValue ( SN  ; 1 )  & GetValue ( VWD ; 3 ) & ¶ &   
              GetValue ( SN  ; 1 )  & GetValue ( VWD ; 4 ) & ¶ &  
              GetValue ( SN  ; 1 )  & GetValue ( VWD ; 5 )
              )
              &
              FilterValues ( T ;
              GetValue ( SN  ; 2 )  & GetValue ( VWD ; 1 ) & ¶ & 
              GetValue ( SN  ; 2 )  & GetValue ( VWD ; 2 ) & ¶ & 
              GetValue ( SN  ; 2 )  & GetValue ( VWD ; 3 ) & ¶ &   
              GetValue ( SN  ; 2 )  & GetValue ( VWD ; 4 ) & ¶ &  
              GetValue ( SN  ; 2 )  & GetValue ( VWD ; 5 )
              )
              &
              FilterValues ( T ;
              GetValue ( SN  ; 3 )  & GetValue ( VWD ; 1 ) & ¶ & 
              GetValue ( SN  ; 3 )  & GetValue ( VWD ; 2 ) & ¶ & 
              GetValue ( SN  ; 3 )  & GetValue ( VWD ; 3 ) & ¶ &   
              GetValue ( SN  ; 3 )  & GetValue ( VWD ; 4 ) & ¶ &  
              GetValue ( SN  ; 3 )  & GetValue ( VWD ; 5 )
              )
              &
              FilterValues ( T ;
              GetValue ( SN  ; 4 )  & GetValue ( VWD ; 1 ) & ¶ & 
              GetValue ( SN  ; 4 )  & GetValue ( VWD ; 2 ) & ¶ & 
              GetValue ( SN  ; 4 )  & GetValue ( VWD ; 3 ) & ¶ &   
              GetValue ( SN  ; 4 )  & GetValue ( VWD ; 4 ) & ¶ &  
              GetValue ( SN  ; 4 )  & GetValue ( VWD ; 5 )
              )
              &
              FilterValues ( T ;
              GetValue ( SN  ; 5 )  & GetValue ( VWD ; 1 ) & ¶ & 
              GetValue ( SN  ; 5 )  & GetValue ( VWD ; 2 ) & ¶ & 
              GetValue ( SN  ; 5 )  & GetValue ( VWD ; 3 ) & ¶ &   
              GetValue ( SN  ; 5 )  & GetValue ( VWD ; 4 ) & ¶ &  
              GetValue ( SN  ; 5 )  & GetValue ( VWD ; 5 )
              )
              )

              • 4. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE

                So u saying.. with your above filter expression in a loop

                it will allow more values to be processed?  _i_ can't see that possible?

                thats a long expression already for just filtering only 5 items!

                _i_ think your right  it could be shorter by putting it into a Loop process??

                • 5. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE

                  Maybe _i_am wrong!!  Sounds like creating a table adding a relationship creating a layout and adding fields might be more minimal programming less work than evolving a looping expression? 

                  • 6. Re: GLOBAL FIELD ITEMS SORTED INSIDE A VARIABLE

                    No !!  _i_am not wrong !!

                    Here, IS the way, how you sorta value List  inside a global field:

                    BubbleSort ( inputValues ; iterations )

                    Sorts a list of return-separated values.

                     

                    Thank You,

                    Robert