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

Add documentation linking to sqlalchemy #29373

Merged
merged 3 commits into from
Nov 22, 2019
Merged

Conversation

cruzzoe
Copy link
Contributor

@cruzzoe cruzzoe commented Nov 2, 2019

@jreback jreback added Docs IO SQL to_sql, read_sql, read_sql_query labels Nov 2, 2019
@alimcmaster1
Copy link
Member

Hey - Can you submit updates on the same PR #29363 in the future - means we don’t have to re-review..

@cruzzoe
Copy link
Contributor Author

cruzzoe commented Nov 3, 2019 via email

pandas/core/generic.py Outdated Show resolved Hide resolved
@cruzzoe
Copy link
Contributor Author

cruzzoe commented Nov 4, 2019 via email

Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be a personal thing but I find the wording here rather confusing. By saying Closing the connection is handled by the SQLAlchemy Engine I got the impression it was done automatically, but that is not the case. Any chance you can clarify or reword that to make it clear that pandas does nothing special here, i.e. the user is responsible for management of the connection?

There was a previous PR #27972 that was pretty close to getting merged if you'd like to take a look

@alimcmaster1
Copy link
Member

I'm thinking we do something like this - similar to the other PR:

image

@WillAyd do you agree? I also got confused by current wording.

@WillAyd
Copy link
Member

WillAyd commented Nov 4, 2019

Yea that sounds like a great idea

@pep8speaks
Copy link

pep8speaks commented Nov 6, 2019

Hello @cruzzoe! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2019-11-06 20:05:45 UTC

@alimcmaster1
Copy link
Member

LGTM (But I’m on mobile so can’t do a doc build to check how this renders).
CC @WillAyd

library. Legacy support is provided for sqlite3.Connection objects. The user
is responsible for engine disposal and connection closure for the SQLAlchemy
connectable See `here \
<https://docs.sqlalchemy.org/en/13/core/connections.html>`_
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if the blank line is necessary

@WillAyd
Copy link
Member

WillAyd commented Nov 7, 2019

Content looks good. Can you build locally and just post a screenshot of how it renders to be safe?

@WillAyd WillAyd added this to the 1.0 milestone Nov 7, 2019
@cruzzoe
Copy link
Contributor Author

cruzzoe commented Nov 22, 2019

Content looks good. Can you build locally and just post a screenshot of how it renders to be safe?

pd1
pd2

@WillAyd WillAyd merged commit d56c2dc into pandas-dev:master Nov 22, 2019
@WillAyd
Copy link
Member

WillAyd commented Nov 22, 2019

Thanks @cruzzoe !

keechongtan added a commit to keechongtan/pandas that referenced this pull request Nov 25, 2019
…ndexing-1row-df

* upstream/master: (185 commits)
  ENH: add BooleanArray extension array (pandas-dev#29555)
  DOC: Add link to dev calendar and meeting notes (pandas-dev#29737)
  ENH: Add built-in function for Styler to format the text displayed for missing values (pandas-dev#29118)
  DEPR: remove statsmodels/seaborn compat shims (pandas-dev#29822)
  DEPR: remove Index.summary (pandas-dev#29807)
  DEPR: passing an int to read_excel use_cols (pandas-dev#29795)
  STY: fstrings in io.pytables (pandas-dev#29758)
  BUG: Fix melt with mixed int/str columns (pandas-dev#29792)
  TST: add test for ffill/bfill for non unique multilevel (pandas-dev#29763)
  Changed description of parse_dates in read_excel(). (pandas-dev#29796)
  BUG: pivot_table not returning correct type when margin=True and aggfunc='mean'  (pandas-dev#28248)
  REF: Create _lib/window directory (pandas-dev#29817)
  Fixed small mistake (pandas-dev#29815)
  minor cleanups (pandas-dev#29798)
  DEPR: enforce deprecations in core.internals (pandas-dev#29723)
  add test for unused level raises KeyError (pandas-dev#29760)
  Add documentation linking to sqlalchemy (pandas-dev#29373)
  io/parsers: ensure decimal is str on PythonParser (pandas-dev#29743)
  Reenabled no-unused-function (pandas-dev#29767)
  CLN:F-string in pandas/_libs/tslibs/*.pyx (pandas-dev#29775)
  ...

# Conflicts:
#	pandas/tests/frame/indexing/test_indexing.py
proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Docs IO SQL to_sql, read_sql, read_sql_query
Projects
None yet
Development

Successfully merging this pull request may close these issues.

It is not clear whether database connection need to be closed manually after calling pd.read_sql()
5 participants