更新时间:2023-01-21 10:51:46
首先,Excel 中的 100k 行听起来很糟糕,当然这需要一段时间.这将需要一段时间才能打开.如果您必须这样做,请尝试:
First, 100k rows in Excel sounds like a horrible idea and of course it'll take awhile. This is going to take awhile just to open. If you MUST do this try:
SELECT order_id,product_name,qty
FROM orders
INTO OUTFILE '/tmp/orders.csv'
FIELDS TERMINATED BY ','
ENCLOSED BY '"'
LINES TERMINATED BY '
'
这应该会给你一个名为:/tmp/orders.csv
的文件,它将在 Excel 中打开.
This should give you a file called: /tmp/orders.csv
which will open in Excel.