Data transfer between files , SQL Database and Dataframes Type C Sumita arora IP Solution


Q1. Write a program read details such as Item, Sales made in a dataframe and then store this data in a CSV file.


Q2. Write a program to read data from a CSV file where separator character is '@'. Make sure that :
* the top row is used as data, not as column headers.
* only 20 rows are read into dataframe.



Q3. Write a program to get following data in two dataframes :

Df1
Roll no    Name
1    ABC
2    DEF
:    :
 

Df2
Roll no    Marks 1    Marks 2    Marks 3
1    70    80    75
2    60    65    70
:    :    :    :


Store these dataframes as two separate tables in the same database.



Q4. You have a database on MySQL namely school having three tables in it - Student, Subject, Teacher. Write a program to store these tables in three dataframes.


Q5. The Dataframe SDF stores the sales records of 100 salesmen. Write a program to store this as a table in database namely "company" on MySQL.


Q6. Consider the SDF dataframe storing the sales records of 100 salesmen, write a program that stores only the first 25 rows of the dataframe in a table on MySQL database.


Q7. The sales table of company databse of MySQL stores the sales records of 100 salesmen. Write a program to load only those records in datafrem which have made sales more than of Rs 50000/- .



Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post