python ¿Ä¸ê¿Ä¨é·JÁ` (¥þ³¡)"¸ê®Æ
- ©«¤l
- 55
- ¥DÃD
- 1
- ºëµØ
- 0
- ¿n¤À
- 81
- ÂI¦W
- 0
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 10
- ¾\ŪÅv
- 20
- µù¥U®É¶¡
- 2016-5-15
- ³Ì«áµn¿ý
- 2018-11-1
|
¨ä¹ê§A´£¨ìªº ¡G
"¥Ø«eªº·Qªk¬O python §ì¨ú¸ê®Æ¦Ü sqlite3¡Avba ±q sqlite3 ¨ú¥X¸ê®Æ"
¦b¹ê°È¤W³oºØ ...
c_c_lai µoªí©ó 2016-9-30 15:22
ì¨Ó¦p¦¹¡A¤p§Ì¬O¬Ýªø´Á¤ë½uªº¡A©Ò¥H¬On²Îp¾ú¥v¸ê®Æ¨S¦³¿ù
½u¤W§Y®É§@·~ ¤p§Ì¨S¿ëªk¡Aì¨Ó¬O¾Þ§@¤âªkªº¤£¦P
¬G¡Aªd¥Îpython¨ú¥Xsql¤ºªºªí®æ¡A¥u¬O³æ¯Ânµe¹Ï¡H
¦L¹³¤¤ ¥xÆWªº ½u¤W§Y®É§@·~ ³£¬O¥Î excel ¡]°ê¥~Å¥»¡§ï±¼¤F¡^
¥Îvba¤~¥i¥H§Y®É¤¬°Ê pythonÀ³¸ÓÁÙ¤£¦æ~~¤£¹L¤]¤£¤@©w¡A»¡¤£©w¦hgoogle ´N¦³°ª¤â§@¥X¨Ó¤F©O
ps:«y«y~~¤j®a¤W¯Z¤£¤W¯Zªº¦b²á³oÓ¡A«¢«¢«¢ |
|
|
|
|
|
|
- ©«¤l
- 552
- ¥DÃD
- 3
- ºëµØ
- 0
- ¿n¤À
- 578
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office 2010
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-2-8
- ³Ì«áµn¿ý
- 2024-7-9
|
¦^´_ 49# c_c_lai
§A°õ¦æªº±¡ªp¡A¯uªº«Ü©_©Ç¡I§Ú°õ¦æ¤F3¦¸±q2016/1/1¨ì2016/9/29 ¤]³£¨S¦³±o¨ì¹³§A¤@¼Ëªºµ²ªG
§A¦A§â¸ê®Æ®w§R±¼¡AÆ[¹î²Ä¤@¦¸¬O¤£¬O·|¤£§¹¾ã¡A±q2016/1/1¨ì2016/9/29¦@¦³170µ§¸ê®Æ¡A¬Ý¬O¤£¬O·|¤£°÷
§Úµ{¦¡¸Ì±¡A¥u¦³´¡¤JINSERT INTO...¨Ã¨S¦³×§ïªº»y¥y¦Ó¥B·í¦³«ÂÐȮɡA¨Ã¤£·|°õ¦æ¥ô¦ó°Ê§@
except Exception as e:
pass
¦A³Â·Ð§A¤F |
|
|
|
|
|
|
- ©«¤l
- 552
- ¥DÃD
- 3
- ºëµØ
- 0
- ¿n¤À
- 578
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office 2010
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-2-8
- ³Ì«áµn¿ý
- 2024-7-9
|
¥Ñ©ó sqlite3 ¦b¤é´Á®É¶¡ ¬O¥H¤å¦r¦ê¦s¤J¡A¦Ó«D¥H¤é´Á®É¶¡®æ¦¡¦s¤J(¦p¡G#2016/01/06#)
¦Ósqlite3ªºdate¨ç¼Æªº¤é´Á®æ¦¡¥²¶·¹³'2016-01-06'¦~¤ë¤é»Ý¥H'-'¹j¶} ¡AY¥H'2016/01/06' ±×½u '/'¹j¶}¡A¥HSQL»yªk·|µLªkpºâ
©Ò¥H¦b¦s¤Jsqlite3¸ê®Æ®wªº¤é´Á¡A¥²¶·¥ý³B²z
¦b dd=dat.strftime('%Y/%m/%d')ªº¤U¦æ»Ý¥[¤J¥t¤@¥y
sqldate=dat.strftime('%Y-%m-%d')
¦Ó³o¥yadd_data(regs=re,date=dd)¥²¶·×§ï¬°
add_data(regs=re,date=sqldate)
¦b¥H«áªº¤é´Á³B²z¡A´N·|®e©ö³B²z¤F
sqlite3¦b¤é´Á¬d¸ß¤è±¡A¨Ò¦p»¡n¬d¸ß '2016-01-01' ¨ì '2016-01-31'
¦bSQL»yªk¤è± ì¨Óªº¥Îªk WHERE ¤é´Á BETWEEN '2016-01-01' AND '2016-01-31'
¦Ósqlite3 «o¤£¯à¥H BETWEEN ¥h³B²z¡A´N¹³«e±»¡ªº¡A¤é´Á®É¶¡ ¬O¥H¤å¦r¦ê¦s¤J¡A¤å¦r¦ê¤£¯à¥Î¦b¤é´Á®É¶¡³B²z
©Ò¥Hsqlite3ªºSQL»yªk¬°
"select * from [0050] where julianday(¤é´Á)>=julianday('2016-01-01') and julianday(¤é´Á)<=julianday('2016-01-31')" |
|
|
|
|
|
|
- ©«¤l
- 2035
- ¥DÃD
- 24
- ºëµØ
- 0
- ¿n¤À
- 2031
- ÂI¦W
- 0
- §@·~¨t²Î
- Win7
- ³nÅ骩¥»
- Office2010
- ¾\ŪÅv
- 100
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2012-3-22
- ³Ì«áµn¿ý
- 2024-2-1
|
¦^´_ 52# lpk187
§Úªº¬O 179 Records¡C
|
|
|
|
|
|
|
- ©«¤l
- 1
- ¥DÃD
- 0
- ºëµØ
- 0
- ¿n¤À
- 1
- ÂI¦W
- 0
- §@·~¨t²Î
- win 10
- ³nÅ骩¥»
- Excel
- ¾\ŪÅv
- 10
- µù¥U®É¶¡
- 2016-10-8
- ³Ì«áµn¿ý
- 2019-9-6
|
|
|
|
|
|
|
- ©«¤l
- 16
- ¥DÃD
- 2
- ºëµØ
- 0
- ¿n¤À
- 66
- ÂI¦W
- 85
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- excel
- ¾\ŪÅv
- 20
- µù¥U®É¶¡
- 2016-8-24
- ³Ì«áµn¿ý
- 2024-11-14
|
½Ð°Ý¦U¦ì¤j¤j¡A³Ìªñ¤£·Q±qÃÒ¥æ©Ò§ì¸ê®Æ¡A§ï¦V¹d¦ëºô¡A¤£¹L¦bºô¶¸ÑªR¤W¨S¸gÅç(¤§«e¬O½Ð±Ð§O¤H«á¡A¦A¨Ì¼Ë¹º¸¬ÄªºCºC§ï¥X¦Û¤w·Qnªº)
ìµ{¦¡³¡¥÷Àɦpªþ¥ó¡A
Y§ï¥Ñ¹d¦ëºô¤U¸ü¸ê®Æªº¸Ü¡A±qºô¸ô¤W¬Ý¤å³¹¡A¨ä¤¤§ï¦¨¥H¤U¡A¤£¹L¦n¹³¨S¿ìªk°e¥X¬d¸ß¡A·Q½Ð±Ð¬Oþ¸Ì¥X°ÝÃD??
= " cnyes.com/twstock/ps_historyprice/" + (cell21)+".htm"
classSelectTextStart = (str(yy-1)+"/"+str(mm)+"/"+str(dd))
classSelectTextEND = (str(yy)+"/"+str(mm)+"/"+str(dd))
browser.find_element_by_id("ctl00_ContentPlaceHolder1_startText").send_keys(classSelectTextStart)
browser .find_element_by_id("ctl00_ContentPlaceHolder1_endText").send_keys(classSelectTextEND)
browser.find_element_by_id("ctl00_ContentPlaceHolder1_submitBut").send_keys(Keys.ENTER)
time.sleep(10) |
|
|
|
|
|
|
- ©«¤l
- 1
- ¥DÃD
- 0
- ºëµØ
- 0
- ¿n¤À
- 1
- ÂI¦W
- 0
- §@·~¨t²Î
- WIN10
- ³nÅ骩¥»
- OFFICE2017
- ¾\ŪÅv
- 10
- µù¥U®É¶¡
- 2019-11-10
- ³Ì«áµn¿ý
- 2019-11-10
|
¤p§Ì¬Oµ{¦¡·s¤â¡A©Ò¥H¤°»ò³£¤£À´¡A·|¶Ãµo°Ý¡A½Ð¨£½Ì¼K~~ |
|
|
|
|
|
|