Global Mapper v25.0

Need help writing a script

Terry333
Terry333 Global Mapper UserTrusted User
edited August 2009 in Technical Support
I have tried to write a script using the GENERATE_REPORT command to read a PGDB, 800+MB and 750M+ records, that I have loaded into GM 11 and write a csv file. All I get is errors.

What I would like for the csv to contain would be the field name, in this case LINE_ID, and the value of that field, i.e. 100, but no matter how many records have a LINE_ID of 100 I only want it to show up once in my csv.
So the csv would look like:

LINE_ID,100
LINE_ID,124
.
.
.
LINE_ID,945

Is this possible to do with GM scripting or is there a better way?

Thanks,
Terry

Comments

  • global_mapper
    global_mapper Administrator
    edited August 2009
    Terry,

    What does your script command look like? I would try something like the following to get what you are after:

    GENERATE_REPORT OUTPUT_FILENAME="c:\my_output_path\my_report.csv" REPORT_ATTR="LINE_ID"

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • Terry333
    Terry333 Global Mapper User Trusted User
    edited August 2009
    My script had the same commands and parameter/value paris as yours except I put each one on a separate line. Once I made the changes it ran fine.

    I read through the scripting language reference again and though it is not specifically stated that the command and parameter/value pairs should be on the same line, no LF/CR after the command and after each parameter/value pair, reading the reference and looking at your example it does seem that it is implied. Will have to remember that.

    Thanks for your help. Great support as always.

    Terry