Database Management
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesDatabase Management

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old July 25th, 2003, 07:28 AM
jharber15 jharber15 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 41 jharber15 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Using SQL to export Access Database to file

Hi guys,

I have been trying to export a database to file with no delimiters currently. Eventually, I need to put in the delimiters, but I'd like to do this step by step. I want to run this sql statement on my export.

SELECT [Transactions].[transaction id], [Transactions].[sequence number], [Transactions].[transaction code], [Transactions].[current location], [Transactions].[patients last name], [Transactions].[patients FIRST name], [Transactions].[patient id number], [Transactions].[admit / discharge date], [Transactions].[admit / discharge time], [Transactions].[patient age], [Transactions].[patient sex], [Transactions].[patients old roombed]
FROM Transactions
WHERE ((([Transactions].[Include])=Yes));

Sorry, that it's somewhat messy. I just copied it out of my old Access app that I used it for. Anyways, I want to run that and then take those records to file. I already have the form set up for the user to edit all records, but now I have to get into this. Thanks for the help guys!

Reply With Quote
  #2  
Old July 25th, 2003, 03:32 PM
victorpendleton victorpendleton is offline
Contributing User
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Jan 2003
Location: No es importante
Posts: 2,065 victorpendleton User rank is Private First Class (20 - 50 Reputation Level)victorpendleton User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 6 h 31 m 56 sec
Reputation Power: 8
Are you wanting to pull data from access and place in a text file? Is this initiated from an application or on schedule?

Reply With Quote
  #3  
Old July 25th, 2003, 03:38 PM
jharber15 jharber15 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 41 jharber15 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
I want to do this on demand. I want to have an export button that you click to take the database to text file with the specs i talked about earlier. Thanks for helping out.

Jason

Reply With Quote
  #4  
Old July 25th, 2003, 03:56 PM
victorpendleton victorpendleton is offline
Contributing User
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Jan 2003
Location: No es importante
Posts: 2,065 victorpendleton User rank is Private First Class (20 - 50 Reputation Level)victorpendleton User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 6 h 31 m 56 sec
Reputation Power: 8
One possible solution create a macro to execute a predefined query and export data.
...
You could also create a module that will open a text file and the data to this text.

Reply With Quote
  #5  
Old July 29th, 2003, 02:28 PM
jharber15 jharber15 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 41 jharber15 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
i have the data now going to file, but it is going by default with commas and quotes

"data", "data1", "data2",

Like that. How can i get rid of these quotes and commas

Reply With Quote
  #6  
Old July 30th, 2003, 12:26 PM
victorpendleton victorpendleton is offline
Contributing User
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Jan 2003
Location: No es importante
Posts: 2,065 victorpendleton User rank is Private First Class (20 - 50 Reputation Level)victorpendleton User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 6 h 31 m 56 sec
Reputation Power: 8
How are you exporting the data? Are you using MS Access? If so, check to see if you can adjust/edit the delimiters.

Reply With Quote
  #7  
Old August 29th, 2003, 03:49 AM
Meff Meff is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Location: Lithuania
Posts: 1 Meff User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to Meff Send a message via Yahoo to Meff
Question

Can I ask, how could you do the data export with SQL sentence? Can you, please, write me that line?

Thank you.

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesDatabase Management > Using SQL to export Access Database to file


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway