自由講場

跳至

首頁
12

尾頁
   7


男爵府

積分: 5826


1#
發表於 20-4-8 19:11 |只看該作者
請問有無人識點在 excel csv format 內保留到 0 字開頭既 data..
例如係 account number 0012335, 一用 csv (comma delimited) 全部 0 開頭都 truncated... 請賜教,謝謝


子爵府

積分: 11324

好媽媽勳章 醒目開學勳章 畀面勳章 環保接龍勳章 大廚勳章


2#
發表於 20-4-8 19:14 |只看該作者
chupachup 發表於 20-4-8 19:11
請問有無人識點在 excel csv format 內保留到 0 字開頭既 data..
例如係 account number 0012335, 一用 csv ...

喺0前面加「'」


珍珠宮

積分: 31711

母親節2025勳章 2025勳章 2025勳章蛇年勳章 2024年龍年勳章 牛年勳章


3#
發表於 20-4-8 19:15 |只看該作者

回覆樓主:

0字前面加 ' 就可以


公爵府

積分: 26533


4#
發表於 20-4-8 19:20 |只看該作者
chupachup 發表於 20-4-8 19:11
請問有無人識點在 excel csv format 內保留到 0 字開頭既 data..
例如係 account number 0012335, 一用 csv ...

本帖最後由 WWT1234 於 20-4-8 19:36 編輯

最簡單係定嗰個column (account number)係text
並唔係general

myimage.jpg


水晶宮

積分: 56044


5#
發表於 20-4-8 19:27 |只看該作者
在 "儲存格格式" 內自訂 00#####


侯爵府

積分: 23448


6#
發表於 20-4-8 21:01 |只看該作者

回覆樓主:

加左 ' 或format set左00###係咪已運算不到?


珊瑚宮

積分: 111301


7#
發表於 20-4-8 21:29 |只看該作者

回覆樓主:

試吓開個blank worksheet, import 你呢個csv file 過嚟,跟住好似上講面……揀text

csv 如果有呢d …就唔可以直接開,開咗data 就會distorted

小女子才疏,以上係我所理解


珊瑚宮

積分: 111301


8#
發表於 20-4-8 21:32 |只看該作者
bing-jing 發表於 20-4-8 21:29
試吓開個blank worksheet, import 你呢個csv file 過嚟,跟住好似上講面……揀text

csv 如果有呢d …就唔 ...

import 過嚟之後,跟4樓講法去做


水晶宮

積分: 59017

2025中秋節勳章 父親節2025勳章 2024年龍年勳章 睛靈勳章


9#
發表於 20-4-8 21:51 |只看該作者
本帖最後由 Anka 於 20-4-8 21:53 編輯
chupachup 發表於 20-4-8 19:11
請問有無人識點在 excel csv format 內保留到 0 字開頭既 data..
例如係 account number 0012335, 一用 csv ...

https://www.ablebits.com/office-addins-blog/2017/01/18/add-leading-zeros-excel/

How to show leading zeroes in Excel using a custom number formatTo display leading zeroes, apply a custom number format by performing these steps:
  • Select a cell(s) where you want to show leading zeros, and press Ctrl+1 to open the Format Cells dialog.
  • Under Category, select Custom.
  • Type a format code in the Type box.In most cases, you will need a format code consisting of 0 placeholders, like 00. The number of zeros in the format code corresponds to the total number of digits you want to show
  • in a cell (you will find a few examples below).
  • Click OK to save the changes.

For example, to add leading zeros to create a 5-digit number, use the following format code: 00000





男爵府

積分: 5826


10#
發表於 20-4-9 10:26 |只看該作者
honeybear0207 發表於 20-4-8 19:14
喺0前面加「'」

已試過但一開 .csv file, leading zero 全 truncated.. 要 system bulk upload data, 所以要 load csv format 但一直揾唔到方法 save leading zero...


男爵府

積分: 5826


11#
發表於 20-4-9 10:27 |只看該作者
apelok 發表於 20-4-8 19:15
0字前面加 ' 就可以

試左但一開 .csv file 就無晒 leading zero


男爵府

積分: 5826


12#
發表於 20-4-9 10:28 |只看該作者
WWT1234 發表於 20-4-8 19:20
本帖最後由 WWT1234 於 20-4-8 19:36 編輯

最簡單係定嗰個column (account number)係text

已試左,text format also custom format, 但一開就無晒 leading zero


男爵府

積分: 5826


13#
發表於 20-4-9 10:28 |只看該作者
howmuch 發表於 20-4-8 19:27
在 "儲存格格式" 內自訂 00#####

已試左,custom format also text format, 但一開就無晒 leading zero


男爵府

積分: 5826


14#
發表於 20-4-9 10:30 |只看該作者
29XX86 發表於 20-4-8 21:01
加左 ' 或format set左00###係咪已運算不到?

那個 value 是 account id 運算不到都 ok 但問題係我 save 唔到整個 0 開頭既號碼在.csv format 檔度... 一一定要 csv format 因為要做 system bulk upload..


公爵府

積分: 26533


15#
發表於 20-4-9 11:50 |只看該作者
chupachup 發表於 20-4-9 10:30
那個 value 是 account id 運算不到都 ok 但問題係我 save 唔到整個 0 開頭既號碼在.csv format 檔度... ...

請問你係想從excel 輸出(export) csv 檔案
定係
滙入(import)一個csv 檔案?


禁止用戶名稱、暱稱、頭銜、頭像、簽名欄,帶有商業/個人/團體 宣傳或推介成份,包括圖片、字句、超連結


男爵府

積分: 5826


16#
發表於 20-4-9 12:47 |只看該作者
WWT1234 發表於 20-4-9 11:50
請問你係想從excel 輸出(export) csv 檔案
定係
滙入(import)一個csv 檔案?

輸出一個有 0 開頭值的 csv 檔案做 system bulk upload


侯爵府

積分: 21386


17#
發表於 20-4-9 12:50 |只看該作者
個 .CSV 本身有冇 leading zeros?

用 Notepad 開來睇睇先

chupachup 發表於 20-4-9 10:27
試左但一開 .csv file 就無晒 leading zero


男爵府

積分: 5826


18#
發表於 20-4-9 13:23 |只看該作者
TinyTomato 發表於 20-4-9 12:50
個 .CSV 本身有冇 leading zeros?

用 Notepad 開來睇睇先

其實 source file 係 .xls format 有 leading zero, 但做 system upload 只可用 .csv,所以要由 xls 轉做 .csv 而又保留 leading zero.. 謝謝


公爵府

積分: 26533


19#
發表於 20-4-9 13:33 |只看該作者
chupachup 發表於 20-4-9 12:47
輸出一個有 0 開頭值的 csv 檔案做 system bulk upload

本帖最後由 WWT1234 於 20-4-9 13:56 編輯

明白,

試吓:
圓1.) 簡單啲用三個columns做例子
Column A 係Account code
Column B 係particular/ Account name
Column C 係transaction amount / Balance.
圖2.)column A & B , format 係text , column C 係number
圖3.) File ->Save as
File name: b (你自己輸入返自己個檔案名稱
Save as type: 必須揀CSV ( MS DOS)
然後Click “Save” button
圖4.)用notepad 開 b.csv

祝好運

(因為發佈咗好多次啲圖都上存唔到,我會分開發佈)


公爵府

積分: 26533


20#
發表於 20-4-9 13:44 |只看該作者
WWT1234 發表於 20-4-9 13:33
本帖最後由 WWT1234 於 20-4-9 13:37 編輯

明白,

圖1. & 2.

myimage.jpg
myimage.jpg
禁止用戶名稱、暱稱、頭銜、頭像、簽名欄,帶有商業/個人/團體 宣傳或推介成份,包括圖片、字句、超連結

首頁
12

尾頁

跳至
Presslogic Logo
Baby Kingdom Logo