Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

execute_query() can't get the lastrowid when insert the record to DB #13

Open
Donald-Su opened this issue Dec 13, 2022 · 3 comments
Open

Comments

@Donald-Su
Copy link

Use the function of execute_query() to insert the record to DB, can't get lastrowid.

And, the function of execute_query() use with context manager, so can't use same connection to execute conn.execute_query("SELECT LAST_INSERT_ID();") sentence to query the LAST_INSERT_ID().

Donald-Su pushed a commit to Donald-Su/pymysql-pool that referenced this issue Dec 20, 2022
@gzwillyy
Copy link

gzwillyy commented Feb 1, 2023

cur.rowcount , this return is also useful.
The version on pypi is 0.3.7, hope to release a new version.

@jkklee
Copy link
Owner

jkklee commented Feb 6, 2023

is also useful.
The version on pypi is 0.3.7, hope to release a new version.

under consideration

@jkklee
Copy link
Owner

jkklee commented Apr 25, 2023

please try v.0.4.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants