Code

Opened 6 years ago

Closed 6 years ago

#9190 closed (invalid)

problem in tutorial

Reported by: webcomm Owned by: nobody
Component: Documentation Version: 1.0
Severity: Keywords: models, unicode
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description (last modified by kmtracey)

At http://docs.djangoproject.com/en/dev/intro/tutorial01/#intro-tutorial01 it doesn't tell you that you have to use the sql and syncdb commands again after you add the __unicode__() method to the model and upload the model. I figured that out by trial and error; the documentation should be more explicit.

Attachments (0)

Change History (1)

comment:1 Changed 6 years ago by kmtracey

  • Description modified (diff)
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to invalid
  • Status changed from new to closed

It isn't necessary to run sql (which actually does nothing with the database, it just prints out statements for your information) or syncdb after adding a __unicode__() method to a model. Syncdb creates tables, you only need to run it when you add a model to your application. I am not sure what you mean by "upload the model" as the word "upload" doesn't appear on the page you pointed to. I'm not really sure what happened in your case that was fixed by running syncdb, but telling people to re-run it after adding the __unicode__() method is not correct.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.