<cfset commalist = valuelist(GetAlias.env_var)>

INSERT INTO data2 (strVar) values (#commalist#)


----- Original Message -----
From: "FlashGuy" <[EMAIL PROTECTED]>
To: "CF-Community" <[EMAIL PROTECTED]>
Sent: Tuesday, October 29, 2002 5:12 PM
Subject: Reading database and inserting fields into another database


> HI,
>
> I need to read in the field "env_var" from one database ("data1") and
insert the results into another database as a comma-delimited text.
>
> <cfquery name="GetAlias" datasource="data1" dbtype="ODBC">
> SELECT      env_var
> FROM        data1
> </cfquery>
>
> Output example:
>
> file1 file2 file3 file4 file5 etc...
>
> Insert results of GetAlias.env_var into database ("data2") into field
"strVar" as a comma-delimited field.
>
> strVar = "file1,file2,file3,file4,file5,etc...
>
> Can I do this with just
>
>
> ---------------------------------------------------
> Colonel Nathan R. Jessop
> Commanding Officer
> Marine Ground Forces
> Guatanamo Bay, Cuba
> ---------------------------------------------------
>
>
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=5
Subscription: 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_community
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Reply via email to