Ravindra Bagale · Data Scienceसर्व coursesया course चे lessonsशोधाEnglish

Data Science · मराठी आवृत्ती

24.1 SQL मधून pandas मध्ये का आणायचं

By Ravindra Bagale

या course चे सर्व chapters (py + ch)

हे का शिकायचं?

Database सत्य स्रोत. pandas मध्ये cleaning, groupby, charts सोपे. दोन्हीची ताकद वापरा.

हे काय आहे?

SQL = filter/join जवळ data. pandas = exploratory analysis. थोडे rows आणा, सर्व database RAM मध्ये ओढू नका.

कसं करायचं?

Step 1. प्रश्न लिहा.

Step 2. SQL मध्ये आधी filter.

Step 3. pandas मध्ये आणा.

Step 4. shape आणि head तपासा.

उदाहरणं: copy करा आणि चालवा

Store of truth You pull with You analyse in
MySQL / Postgres / SQLite SQL SELECT pandas DataFrame
Shared drive CSV pd.read_csv same DataFrame tools

उदाहरण A — When CSV is enough.

Raja downloads last month’s closed orders once for a training notebook. CSV is fine. No live connection needed.

उदाहरण B — When SQL is better (fictional).

Amir’s manager asks at 4 pm IST: “Delivered GMV today for Pune dark stores only.” The morning CSV missed the afternoon rush. A small SELECT … WHERE order_date = CURRENT_DATE AND city = 'Pune' into pandas answers in one cell.

उदाहरण C — Stack sketch.

Store of truth You pull with You analyse in
MySQL / Postgres / SQLite SQL SELECT pandas DataFrame
Shared drive CSV pd.read_csv same DataFrame tools