navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
FrontPage Alternative
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

Reading data from a CSV locally and inserting them in to a DB on a webserver

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> Reading data from a CSV locally and inserting them in to a DB on a webserver
Page: [1]
 
and13345

 

Posts: 100
Joined: 10/7/2003
Status: offline

 
Reading data from a CSV locally and inserting them in t... - 10/25/2007 18:10:55   
I have seen posts that show examples of reading data from a CSV that is located on the hard drive of a webserver, but I am wondering if there is a way to read a CSV that is on my local machine and have that data inserted in to a DB that is located on the webserver. What I am trying to get around is having to upload the CSV to the server before inporting the data.
Spooky

 

Posts: 26606
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: Reading data from a CSV locally and inserting them ... - 10/26/2007 0:06:52   
Cut and paste the contents of the CSV file into a textarea?

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to and13345)
and13345

 

Posts: 100
Joined: 10/7/2003
Status: offline

 
RE: Reading data from a CSV locally and inserting them ... - 10/26/2007 0:49:27   
I am not sure I fully understand your post. Are you saying I can take and copy the contents of the CSV (see example below) and paste it in to a textarea in a form page and then read that in to a DB?.

Can you point me to an example of this?

"Parameter","Value","Description"
"AAC","Option is disabled","Allow AAC and M4A encoding"
"AAC_Decode","Option is disabled","Allow AAC and M4A decoding"
"AC3Decode","Option is disabled","Allow AC3 decoding in the build"
"AC3DecodePro","Option is disabled","Allow AC3 Decoding of commercial AC3 files."
"AC3Encode","Option is disabled","Allow AC3 Encoding in the build"

(in reply to Spooky)
William Lee

 

Posts: 1179
Joined: 1/25/2002
From: Singapore
Status: offline

 
RE: Reading data from a CSV locally and inserting them ... - 10/29/2007 5:17:51   
quote:

ORIGINAL: and13345

Are you saying I can take and copy the contents of the CSV (see example below) and paste it in to a textarea in a form page and then read that in to a DB?.


Yes.

quote:


Can you point me to an example of this?

"Parameter","Value","Description"
"AAC","Option is disabled","Allow AAC and M4A encoding"
"AAC_Decode","Option is disabled","Allow AAC and M4A decoding"
"AC3Decode","Option is disabled","Allow AC3 decoding in the build"
"AC3DecodePro","Option is disabled","Allow AC3 Decoding of commercial AC3 files."
"AC3Encode","Option is disabled","Allow AC3 Encoding in the build"


Basically you would need to split the textarea data into array for each line.

For each in array(skipping the first which is the header), you would execuate the INSERT eg
"Insert into Table (" & array(1) & ") Values "(" & array(n) & ")"

HTH

_____________________________

William Lee

pǝssǝɟoɹd-ɟ1ǝs ʎɥʇɹoʍʇsnɹʇ ʇsoɯ ɹnoʎ
nɹnb ǝsɐqɐʇɐp & dsɐ ,ʍɹp ,ǝbɐdʇuoɹɟ





(in reply to and13345)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> Reading data from a CSV locally and inserting them in to a DB on a webserver
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts