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 7 476 Aug-02-2022, 09:45 AM
Last Post: sshree43
  How to extract specific data from .SRC (note pad file) Shinny_Shin 2 293 Jul-27-2022, 12:31 PM
Last Post: Larz60+
  panda table data kucingkembar 0 426 Mar-01-2022, 10:38 PM
Last Post: kucingkembar
  Sorting table data Blacktime2 1 603 Feb-26-2022, 07:05 PM
Last Post: ibreeden
  Strategy on updating edits back to data table and object variables hammer 0 649 Dec-11-2021, 02:58 PM
Last Post: hammer
  Flask dynamic data ? korenron 10 2,482 Nov-17-2021, 07:37 AM
Last Post: korenron
  SQLALCHEMY - Not selecting data from table jamesaarr 4 1,190 Nov-02-2021, 03:02 PM
Last Post: Larz60+
  Build a matrix by pressing buttons of an interface in Tkinter which extract data from juandiegopulla 1 862 Sep-13-2021, 07:28 PM
Last Post: deanhystad
  Python Pandas: How do I extract all the >1000 data from a certain column? JaneTan 0 1,021 Jul-17-2021, 09:09 AM
Last Post: JaneTan
  SaltStack: MySQL returner save less data into Database table columns xtc14 2 1,337 Jul-02-2021, 02:19 PM
Last Post: xtc14

Forum Jump:

User Panel Messages

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