12345678910111213141516171819202122232425 |
- from sqlalchemy import Boolean, Column, ForeignKey, Integer, String
- from app.models.database import BaseModel
- class DataTable(BaseModel):
- __tablename__ = "data_table"
- id = Column(Integer, primary_key=True, index=True)
- # 数据库名称
- database_name = Column(String)
- # 数据表名称
- table_name = Column(String, nullable=False)
- # 源(0:数据湖;1:ailab)
- source = Column(Integer, nullable=False)
- # 类型(0:被分享;1:自建;2:导入)
- type = Column(Integer, nullable=False)
- # 项目id
- project_id = Column(String, nullable=False)
- # hdfs的表的path
- table_path = Column(String)
- # 创建时间
- create_time = Column(Integer, nullable=False)
- # 用户id
- user_id = Column(String, nullable=False)
|