<id_компонента> <id_продукта> <количество>
<id_рецепта> <id_компонента>
# -*- coding: utf-8 -*-
select *
from
(
SELECT
T0.ID ID,
T0.ClientID client_id,
T0.ClassID ClassID,
T0.SeniorID SeniorID,
T0.DNumber DNumber,
(SELECT NotEmptyStr(SO1.fullName, SO1.name) FullName$
FROM ActivityDirections SO1
WHERE SO1.ID = T0.ActivityDirection
) as AutoAlias_10750549,
(SELECT SO1.ID id_type
FROM ActivityDirections SO1
WHERE SO1.ID = T0.ActivityDirection
) as typeid
FROM T0
) x
where x.typeid IN (192922, 19333, 2323)
class Sensor(db.Model):
__tablename__ = 'sensor'
id = db.Column(db.Integer, primary_key=True)
name = db.Column(db.String(64), index=True, unique=False)
unit_id = db.Column(db.Integer, db.ForeignKey('unit.id'))
class Unit(db.Model):
__tablename__ = 'unit'
id = db.Column(db.Integer, primary_key=True)
name = db.Column(db.String(32), index=True, unique=False)
description = db.Column(db.String(32), index=True, unique=False)
# Это для возможности получения всех ссылающихся на объект Unit объектов Sensor:
sensors = relationship(Sensor, backref="unit_id")
git commit -m "сообщение"
git push origin <ветка>
git remote -v
git fetch origin <ветка>:<локальный псевдоним ветки>