Ready to get started?Download WordPress


Team Rosters
[resolved] CSV with Bats and Throws (6 posts)

  1. lero21
    Posted 8 months ago #

    Hi Mark,
    when importing baseball roster using CSV, it seems like "bats" and "throw" don't want to fit in.
    And the end of the import, here is what I get …

    retval = 1 ID: 2499 K: _mstw_tr_weight V: 145

    retval = 1 ID: 2499 K: _mstw_tr_height V: 5'11"

    retval = 50226 ID: 2499 K: Bats V: L

    retval = 50227 ID: 2499 K: Throws V: R

    I can't see what I'm doing wrong.



  2. Mark O'Donnell
    Plugin Author

    Posted 8 months ago #

    Hey Ron-
    Did you RTFM? That might help, but I don't believe the sample CSV files have Bats and Throws. I'll have a look after I get the Game Schedules fires put out. :)


  3. korben5
    Posted 7 months ago #


    I actually have the same issue and I followed the CSV header design in your manual:

    CVS Column Header -> Database Field
    “First Name” or First” -> first_name
    “Last Name”, “Last” -> last_name
    “Position”, “Pos” -> position
    “Number”, “Nbr”, “#” -> number
    “Weight”, “Wt” -> weight
    “Height”, “Ht” -> height
    “Age” -> age
    “Year” -> year
    “Experience”, “Exp” -> experience
    “Home Town” -> home_town
    “Country” -> country
    “Last School” -> last_school
    “Bats”, “Bat” -> bats
    “Throws”, “Thw”, “Throw” -> throws

    It's a minor issue, but just wanted to confirm that someone else came across it.

  4. Mark O'Donnell
    Plugin Author

    Posted 7 months ago #

    Hi Guys,
    The sample CSV files did not have bats and throws because it was not supported, BUT it was documented as korben5 points out. Oops.

    The development trunk on WordPress.org now contains a revised /includes/mstw-team-rosters-admin.php file which supports Bats, Throws, and Other. It also contains a new /csv-examples/test-baseball.csv file, which I used to test the changes. You can see the results on my MSTW Dev Site. (Scroll down to the 2012 World Champion San Francisco Giants table.) It works for me!!

    Please try out the patch when you have time and let me know how it works for you. I will then publish a new release.

    Thanks for your help in identifying this issue.


    I am going to update the documentation on shoalsummitsolutions.com as soon as this is posted.

  5. korben5
    Posted 6 months ago #

    Hi Mark,

    That worked for me, uploaded b/t perfectly. Thanks for the update!


  6. Mark O'Donnell
    Plugin Author

    Posted 6 months ago #

    Cool. I will release a patch to WordPress.org.
    Thanks for testing it.


You must log in to post.

About this Plugin

About this Topic


No tags yet.