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

The first row from the table is not returned #1035

Closed
Indraja22 opened this issue Nov 5, 2021 · 2 comments
Closed

The first row from the table is not returned #1035

Indraja22 opened this issue Nov 5, 2021 · 2 comments

Comments

@Indraja22
Copy link

Indraja22 commented Nov 5, 2021

Please note first row is getting skipped.
Database : MySQL
Tablesaw dependency :

tech.tablesaw
tablesaw-core
0.42.0

Line of code : System.out.println(Table.read().db(resultSet).printAll());

Result Obtained :
id | description | title |

6670 | This is a complete JavaScript Expert course. | JavaScript Expert |
6671 | This is a complete Java Expert course. | Java Expert |
6679 | This is a complete Java DSA Expert course. | Java DSA Expert |
9990 | This is a complete JavaScript Basics course. | JavaScript Basics |

Actual Data in DB :
mysql> select * from demo_api.course;
+------+----------------------------------------------+-------------------+
| id | description | title |
+------+----------------------------------------------+-------------------+
| 2334 | This is a complete CPP DSA course. | CPP DSA |
| 6670 | This is a complete JavaScript Expert course. | JavaScript Expert |
| 6671 | This is a complete Java Expert course. | Java Expert |
| 6679 | This is a complete Java DSA Expert course. | Java DSA Expert |
| 9990 | This is a complete JavaScript Basics course. | JavaScript Basics |
+------+----------------------------------------------+-------------------+

@lwhite1
Copy link
Collaborator

lwhite1 commented Nov 14, 2021

Did you directly examine the data in the java sql ResultSet to see if it was correct? Tablesaw doesn't actually import from a database, it imports from a JDBC ResultSet object.

There are a number of tests that show that given a resultSet with n records, Tablesaw produces a table with n rows.

@lwhite1
Copy link
Collaborator

lwhite1 commented Mar 27, 2022

closing as can't reproduce

@lwhite1 lwhite1 closed this as completed Mar 27, 2022
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

2 participants