7 Replies Latest reply on Apr 14, 2015 9:52 PM by TKnTexas

    Heading

    TKnTexas

      Title

      Heading

      Post

      I am using a FMP database to manage my end of month accruals.  I create the journal entry.  It prints out great.  I I can create a text file to upload to Great Plains (my accounting program).  However, it does not create the header; it is data only.  The Integration Program presumes a header.  

      How to include the header to my CVS text file?

      As second problem, each export from FMP is writing the data to the same file overwriting the old.  When scripting I do not find any options for REPLACING the file.  Have I overlooked that?

        • 1. Re: Heading
          philmodjunk

          Try exporting to a merge file and then rename the file by changing the file extension.

          A merge file export is a csv export with the field names included as a header.

          I'm not sure that I can believe what you are describing. Each export from FileMaker generates a completely new file. Unless you are using a plug in, there is no way for a data export to modify an existing file.

          • 2. Re: Heading
            TKnTexas

            So I need to delete the existing file, from the prior journal entry, before I export a new journal entry?  

            I guess I can use a *.bat file to rename and one to do the delete call from Script.

             

            • 3. Re: Heading
              philmodjunk

              Or you can use a different file name each time such as including a number field as part of the specified field name an incrementing it each time. Appending text from the current date or timestamp also can be used. (but you have to modify the text to not use the "/" or ":" characters as part of the file name as this will cause an error.)

              This can be done by setting up a $Path variable with the file path and a calculated file name that you then put into the specify File dialog that you open from the export records script step.

              • 4. Re: Heading
                TKnTexas

                Great Plains Integration Manager looks for a specific file name to import the different types of data.  The end-user does not have control over the name of a import file or the location where the file is placed.  Each USER has to place the file in a specific folder on their C-Drive with the specific name.  When generating the from Excel, I could just overwrite the existing file with a new version.

                With FMP I get an error.  What I create I have to make fool-proof for the other users in accounting.  

                • 5. Re: Heading
                  philmodjunk

                  Then it would appear that you need to use either that .BAT file or a file manipulation plug in that can delete specified files.

                  • 6. Re: Heading
                    TKnTexas

                    Thank you Phil, you have been a big help.  Doing it all manual this week has helped develop a great tool for my work.  There are a few other controls I can add that will address what my boss wants that would otherwise be manual with high-lighters.  

                    Have a great weekend.

                    • 7. Re: Heading
                      TKnTexas

                      I got back to this today.  I changed my export type to a MERGE file type.  I did get the headers row.  However, I also got double quotes around the fields' data.  This confuses the import program.  Tab-delimited does not do the double quotes.   I do not think the actual text of the headers matter.  It is just that the Integration Manager is looking for the data to start on row two, after the header.  I am going to approach it from that perspective and play with it.