<p dir="auto">my model:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="class Test(db.Model):
    __tablename__ = &quot;Test&quot;  
    STN = db.Column(db.String(3), nullable=False, info='')
    BEG_DATE = db.Column(db.Date, nullable=False, info='')
    END_DATE = db.Column(db.Date, nullable=False, info='')
    PRICE = db.Column(db.String(3), nullable=False, info='')
    REMARK = db.Column(db.String(255), nullable=True, info='')"><pre class="notranslate"><code class="notranslate">class Test(db.Model):
    __tablename__ = "Test"  
    STN = db.Column(db.String(3), nullable=False, info='')
    BEG_DATE = db.Column(db.Date, nullable=False, info='')
    END_DATE = db.Column(db.Date, nullable=False, info='')
    PRICE = db.Column(db.String(3), nullable=False, info='')
    REMARK = db.Column(db.String(255), nullable=True, info='')
</code></pre></div>
<p dir="auto">when I run my flask app, its tips <code class="notranslate">could not assemble any primary key columns for mapped table</code>,Mysql database can create a database without a primary key, Why do I have to set the primary key?I don't want to set the primary key, how can I solve it?</p>
<p dir="auto"><strong>Migrated issue, originally created by Anonymous</strong></p>
<p dir="auto">Attaching a patch (for 0.6 and for 0.7) to support this:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="    u = table1.update().values(name=table2.c.othername)\
              .where(table2.c.otherid == table1.c.myid)"><pre class="notranslate"><code class="notranslate">    u = table1.update().values(name=table2.c.othername)\
              .where(table2.c.otherid == table1.c.myid)
</code></pre></div>
<p dir="auto">compiling to:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="    UPDATE mytable SET name=myothertable.othername
    FROM myothertable WHERE myothertable.otherid = mytable.myid"><pre class="notranslate"><code class="notranslate">    UPDATE mytable SET name=myothertable.othername
    FROM myothertable WHERE myothertable.otherid = mytable.myid
</code></pre></div>
<p dir="auto">(i.e. the FROM clause is inferred from the extra from-objects in the WHERE clause and the SET columns)</p>
<p dir="auto">Unit tests included. Doesn't break any existing tests in either 0.6 or 0.7 (and I <em>think</em> this doesn't modify behavior in any use case that wasn't broken anyway).</p>
<hr>
<p dir="auto">Attachments: <a href="../wiki/imported_issue_attachments/2166/sqlalchemy-support-update-from-0.6.patch">sqlalchemy-support-update-from-0.6.patch</a> | <a href="../wiki/imported_issue_attachments/2166/sqlalchemy-support-update-from-0.7.patch">sqlalchemy-support-update-from-0.7.patch</a> | <a href="../wiki/imported_issue_attachments/2166/2166.patch">2166.patch</a></p>