Skip to content

DOC: Clarify dispatch behavior of read_sql #18925

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

Merged
merged 2 commits into from
Dec 26, 2017

Conversation

gfyoung
Copy link
Member

@gfyoung gfyoung commented Dec 24, 2017

Wasn't particularly clear or prominent in the docs.

Closes #18861.

@gfyoung gfyoung added Docs IO SQL to_sql, read_sql, read_sql_query labels Dec 24, 2017
@gfyoung gfyoung added this to the 0.23.0 milestone Dec 24, 2017
pandas/io/sql.py Outdated
Parameters
----------
sql : string or SQLAlchemy Selectable (select or text object)
SQL query to be executed.
con : SQLAlchemy connectable(engine/connection) or database string URI
SQL query to be executed or a table name from which to select rows.
Copy link
Member

Choose a reason for hiding this comment

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

I would leave out "from which to select rows" (there is no way to do this)

Copy link
Member Author

Choose a reason for hiding this comment

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

Done.

pandas/io/sql.py Outdated
``read_sql_query`` (for backward compatibility). It will delegate
to the specific function depending on the provided input.

For example, a SQL query will be routed to ``read_sql_query``, while a
Copy link
Member

Choose a reason for hiding this comment

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

I would leave out "For example", as there are no other options.

(I would also keep those two paragraphs as a single paragraph, as it is explaining one topic.

Copy link
Member Author

Choose a reason for hiding this comment

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

Done.

@codecov
Copy link

codecov bot commented Dec 26, 2017

Codecov Report

Merging #18925 into master will decrease coverage by 0.02%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #18925      +/-   ##
==========================================
- Coverage   91.59%   91.57%   -0.03%     
==========================================
  Files         150      150              
  Lines       48959    48959              
==========================================
- Hits        44843    44833      -10     
- Misses       4116     4126      +10
Flag Coverage Δ
#multiple 89.93% <ø> (-0.03%) ⬇️
#single 41.13% <ø> (ø) ⬆️
Impacted Files Coverage Δ
pandas/plotting/_converter.py 65.22% <0%> (-1.74%) ⬇️
pandas/util/testing.py 84.9% <0%> (+0.21%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cdebcf3...31417d0. Read the comment docs.

@gfyoung
Copy link
Member Author

gfyoung commented Dec 26, 2017

@jorisvandenbossche: comments addressed. PTAL.

@jreback jreback merged commit a18d725 into pandas-dev:master Dec 26, 2017
@jreback
Copy link
Contributor

jreback commented Dec 26, 2017

thanks!

@gfyoung gfyoung deleted the sql-doc-clarify branch December 27, 2017 07:24
hexgnu pushed a commit to hexgnu/pandas that referenced this pull request Dec 28, 2017
* DOC: Clarify dispatch behavior of read_sql [ci skip]

Closes pandas-devgh-18861.

* Address reviewer comments
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.

3 participants