473,405 Members | 2,421 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

export from mssql database

Hello,

I try to export a mssql database into a csv-file.

I tried this with asp, but it doesn't work.

<%
Dim objConn
Dim csv_path

Set objConn = Server.CreateObject("ADODB.Connection")
objConn.open "database","username","passwd"
csv_path =Server.MapPath("./") & "\csv_test.csv"
SQL ="SELECT * INTO OUTFILE 'C:\inetpub\wwwroot\csv_test.csv' FIELDS
TERMINATED BY ';' OPTIONALLY ENCLOSED BY '"' FROM GROUPS"
objConn.Execute SQL
objConn.Close
Set objConn = Nothing
%>

There is a problem near 'C:\inetpub\wwwroot\csv_test.csv'
Can anyone help? Thank you.

Manuel
Jul 20 '05 #1
1 5336

"Manuel" <ma********@web.de> wrote in message
news:4a*************************@posting.google.co m...
Hello,

I try to export a mssql database into a csv-file.

I tried this with asp, but it doesn't work.

<%
Dim objConn
Dim csv_path

Set objConn = Server.CreateObject("ADODB.Connection")
objConn.open "database","username","passwd"
csv_path =Server.MapPath("./") & "\csv_test.csv"
SQL ="SELECT * INTO OUTFILE 'C:\inetpub\wwwroot\csv_test.csv' FIELDS
TERMINATED BY ';' OPTIONALLY ENCLOSED BY '"' FROM GROUPS"
objConn.Execute SQL
objConn.Close
Set objConn = Nothing
%>

There is a problem near 'C:\inetpub\wwwroot\csv_test.csv'
Can anyone help? Thank you.

Manuel


You seem to be using MySQL syntax, not MSSQL (Microsoft SQL Server), so I
guess you'll get a better answer in a MySQL forum. If you are using MSSQL,
then I suggest you check out osql.exe, bcp.exe, or DTS.

Simon
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Leader | last post by:
Hi All, I have question and that is-- if i have a database that is implemented in MSDE Now i want the same database in MSSQL. What are the steps i do need to follow for this. Thanks in Advance...
2
by: BUSHII | last post by:
I have big problem. In database MyDB.mdb I have table for example: ORDERS with colums: - Id int - Name varchar(20) Also I create same table in SQL Server 2k. I can manualy export this data...
1
by: thaar | last post by:
hi everybody, iam soory maybe my question is easy, i heard about a product that can solve such problems, but i forgetted. the problem: we have several foxpro6 systems, each one with seperated...
1
by: syska | last post by:
Hi, I talked to a Microsoft person for about 4 month ago, and he said that microsoft was developing a tool/program, so it was easier to deplay the mssql database to the webhost.... at that time...
3
by: Daniel Wetzler | last post by:
Dear MSSQL- experts, I have a strange problem with SQLSERVER 2000. I tried to export a table of about 40000 lines into a text file using the Enterprise manager export assitant. I was astonished...
7
by: eselk | last post by:
I'm doing some speed tests. I created a brand-new table, with just one "Long Integer" field. I'm testing adding 1000 records. If I use the "Export" feature in Access, it takes only a few seconds...
0
by: LizRickaby | last post by:
My client has several Access databased that they wanted converted into MSSQL to be able to access them online (excuse the pun). I added the first Access database, LenderPrograms, as a table in the...
2
by: Rafael tejera | last post by:
Somebody has an example of how to export an image from my database. Sincerely, RT
3
by: Chris McFarling | last post by:
What's the most efficient method to export the result set of a SQL query to a text file using ASP.NET? There could potentially be a few thousand rows.
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.