Python Forum
Need help on extract dynamic table data
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need help on extract dynamic table data
#1
Hi, all

I am trying to extract table data (property lease and sold) from below link:

https://oir.centanet.com/en/transaction/...ntindex=-1

I tried many method to extract, but still fail. Below is my code for your reference. I hope to extract the property sell data and insert into pandas dataframe for easy manage

base_url = str("https://oir.centanet.com/en/transaction/index?daterang=01%2F05%2F2019-29%2F04%2F2021&pageindex=0&pagesize=10&suggestlist=%5B%5D&posttype=0&districts=&sortby=0&usages=&pricetype=0&minprice=&maxprice=&renttype=0&minrent=&maxrent=&minarea=&maxarea=&centabldg=&sellindex=-1&rentindex=-1")

driver.get(base_url)

sleep(30)

tables=WebDriverWait(driver,20).until(EC.presence_of_all_elements_located((By.XPATH,"//*[@id='__layout']/div/div[1]/div/div[3]/div[1]/div[2]/table/tbody")))

for t in range(len(tables)):
    print("element in list: ",tables[t].text)
Thank You for your help
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  extract table from multiple pages sshree43 8 1,193 Dec-12-2022, 10:34 AM
Last Post: arvin
  python multiprocessing help -- to extract 10 sql table into csv mg24 3 418 Nov-20-2022, 11:50 PM
Last Post: mg24
  python Extract sql data by combining below code. mg24 2 304 Oct-03-2022, 10:25 AM
Last Post: mg24
  SQL Alchemy help to extract sql data into csv files mg24 1 258 Sep-30-2022, 04:43 PM
Last Post: Larz60+
  How to extract specific data from .SRC (note pad file) Shinny_Shin 2 509 Jul-27-2022, 12:31 PM
Last Post: Larz60+
  panda table data kucingkembar 0 572 Mar-01-2022, 10:38 PM
Last Post: kucingkembar
  Sorting table data Blacktime2 1 770 Feb-26-2022, 07:05 PM
Last Post: ibreeden
  Strategy on updating edits back to data table and object variables hammer 0 766 Dec-11-2021, 02:58 PM
Last Post: hammer
  Flask dynamic data ? korenron 10 3,736 Nov-17-2021, 07:37 AM
Last Post: korenron
  SQLALCHEMY - Not selecting data from table jamesaarr 4 1,409 Nov-02-2021, 03:02 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020