peewee Documentation Release 3.0.0PostgreSQL Exercises site, then you can load the data into a PostgreSQL database using the following commands: createdb peewee_test psql -U postgres -f clubdata.sql -d peewee_test -x -q To create the schema class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print(some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries0 码力 | 319 页 | 361.50 KB | 1 年前3
peewee Documentation
Release 3.5.0class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField(default=datetime.datetime.now) This allows you to write code like the following: deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries registration_expired == True) .returning(User)) # Send an email to every user that was deactivated. for deactivate_user in query.execute(): send_deactivation_email(deactivated_user) The RETURNING0 码力 | 347 页 | 380.80 KB | 1 年前3
peewee Documentation Release 3.4.0PostgreSQL Exercises site, then you can load the data into a PostgreSQL database using the following commands: createdb peewee_test psql -U postgres -f clubdata.sql -d peewee_test -x -q To create the schema class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print(some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries0 码力 | 349 页 | 382.34 KB | 1 年前3
peewee Documentation Release 3.1.0PostgreSQL Exercises site, then you can load the data into a PostgreSQL database using the following commands: createdb peewee_test psql -U postgres -f clubdata.sql -d peewee_test -x -q To create the schema class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print(some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries0 码力 | 332 页 | 370.77 KB | 1 年前3
peewee Documentation
Release 3.5.0intuitive way: class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField(default=datetime.datetime.now) This allows you to write code like the following: deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries where(User.registration_expired == True) .returning(User)) # Send an email to every user that was deactivated. for deactivate_user in query.execute(): send_deactivation_email(deactivated_user) The RETURNING clause0 码力 | 282 页 | 1.02 MB | 1 年前3
peewee Documentation
Release 3.3.0PostgreSQL Exercises site, then you can load the data into a PostgreSQL database using the following commands: createdb peewee_test psql -U postgres -f clubdata.sql -d peewee_test -x -q To create the schema intuitive way: class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print(some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries0 码力 | 280 页 | 1.02 MB | 1 年前3
peewee Documentation
Release 3.4.0PostgreSQL Exercises site, then you can load the data into a PostgreSQL database using the following commands: createdb peewee_test psql -U postgres -f clubdata.sql -d peewee_test -x -q To create the schema intuitive way: class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print(some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries0 码力 | 284 页 | 1.03 MB | 1 年前3
peewee Documentation Release 3.6.0class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField(default=datetime.datetime.now) This allows you to write code like the following: deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries registration_expired == True) .returning(User)) # Send an email to every user that was deactivated. for deactivate_user in query.execute(): send_deactivation_email(deactivated_user) The RETURNING0 码力 | 377 页 | 399.12 KB | 1 年前3
peewee Documentation
Release 3.6.0Release 3.6.0 class Message(Model): user = ForeignKeyField(User, backref='messages') body = TextField() send_date = DateTimeField(default=datetime.datetime.now) This allows you to write code like the following: deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries where(User.registration_expired == True) .returning(User)) # Send an email to every user that was deactivated. for deactivate_user in query.execute(): send_deactivation_email(deactivated_user) The RETURNING clause0 码力 | 302 页 | 1.02 MB | 1 年前3
peewee Documentation Release 2.10.2Message(Model): user = ForeignKeyField(User, related_name='messages') body = TextField() send_date = DateTimeField() This allows you to write code like the following: >>> print some_message deactivates all user accounts whose registration has expired. After deactivating them, you want to send each user an email letting them know their account was deactivated. Rather than writing two queries registration_expired == True) .returning(User)) # Send an email to every user that was deactivated. for deactivate_user in query.execute(): send_deactivation_email(deactivated_user) The RETURNING0 码力 | 275 页 | 276.96 KB | 1 年前3
共 16 条
- 1
- 2













