Hi All,
My Name Is Mohammad Naveed and this is my First post.
i am new to Python programming and seeking for some help/guidance in correcting my python code.
Here my query is.
1. I have one Excel file which has (7 Tabs).
2. I have one Folder which contains 7 different text file and each text file contains respective Tab SQL Query and each text file name is same as the Tab Name which is available in Excel File.
i have a written a Python code to loop through all the text file one by one and execute that each text file sql query and whatever data will come in output that output data should dump into existing excel file in that respective sheet/tab. i am using pandas to do this however code is working fine but while updating data into excel pandas is removing all existing sheets from file and updating only current output data into excel file.
Example: if python code execute a text file(Filename: Data) and after executing this SQL query we got some data and this data should dump into excel file (sheetname: Data).
My Name Is Mohammad Naveed and this is my First post.
i am new to Python programming and seeking for some help/guidance in correcting my python code.
Here my query is.
1. I have one Excel file which has (7 Tabs).
2. I have one Folder which contains 7 different text file and each text file contains respective Tab SQL Query and each text file name is same as the Tab Name which is available in Excel File.
i have a written a Python code to loop through all the text file one by one and execute that each text file sql query and whatever data will come in output that output data should dump into existing excel file in that respective sheet/tab. i am using pandas to do this however code is working fine but while updating data into excel pandas is removing all existing sheets from file and updating only current output data into excel file.
Example: if python code execute a text file(Filename: Data) and after executing this SQL query we got some data and this data should dump into excel file (sheetname: Data).
Comment