this is my Teackback:
D:\zjm_demo\app>appcfg.py upload_data --config_file=upload/str_loader.py --filename=upload/a.csv --kind=College --url=http://localhost:8100/remote_api
Uploading data records.
app_id argument required for non appspot.com domains
D:\zjm_demo\app>appcfg.py upload_data --app_id=zjm1126 --config_file=upload/str_loader.py --filename=upload/a.csv --kind=College --url=http://localhost:8100/rem
ote_api
Usage: appcfg.py [options] <action>
appcfg.py: error: no such option: --app_id
D:\zjm_demo\app>appcfg.py upload_data app_id=zjm1126 --config_file=upload/str_loader.py --filename=upload/a.csv --kind=College --url=http://localhost:8100/remot
e_api
Usage: appcfg.py [options] upload_data <directory>
appcfg.py: error: Not a directory: app_id=zjm1126
can i upload data to localhost server .
thanks
updated
my ste_loader.py is :
from google.appengine.ext import db
from google.appengine.tools import bulkloader
# 以下是 Model 的 Definition
class College(db.Model):
cid = db.StringProperty(required=True)
name = db.StringProperty(required=True)
# 以下是匯入資料的 class
class CollegeLoader(bulkloader.Loader):
def __init__(self):
bulkloader.Loader.__init__(self, 'College',
[
('cid', str),
('name', lambda x: unicode(x, 'utf-8')),
])
loaders = [CollegeLoader]