Special Characters

2011-09-28 Thread Jason Congerton

Hi

I have to set up a CSV file to feed a product called Lengow. The file has to be 
encoded in UTF-8. Some of the site will be sending in french writing which has 
a lot of accents cedil's etc. 

The site uses wysiwyg text editors, and looking at the source code the special 
characters are not in html they are just showing like this ç. This is 
probably because they are cut and pasted via notepad or word(cleaned).. 

Lengow seem to offer very little assistance into what is wrong with the data 
I'm sending, I have tried a lot of things!! All Lengow say is If you specify 
an UTF-8 encoding then you need to encode special characters according to the 
encoding format.

cf_charsetconvert
replacing characters etc.
wp_product_description = replace(wp_product_description, Aacute;, 
#chr(193)#, ALL);

Any help would be greatly appreciated.

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347761
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Special Characters

2011-09-28 Thread Jason Congerton

Hi Thanks for your reply,

I am investigating your thoughts now, my definition of special characters are 
accents, cedil's, grave's etc. 

The characters display correctly on the web page being served, but when i put 
them into a csv doc I get the glyph problem.

The database is sql set at Latin1_General_CI_AS. I will look at the text editor 
as well.




~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347763
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Compare a Record and insert null values

2009-12-04 Thread Jason Congerton

Hi 

I am storing measurement info for a product, each product has numerous parts, 
and each part has numerous measurements.

Once the product has been created with all its part numbers and measurements i 
need to loop through the measurements and make sure each part has the exact 
same amount of measurements inserting n/a in the appropriate place.

EG:

Product 1
Part No 12
Measurements:  A=12 B=13 C=14

Product 1
Part No 13 
Measurements: A=12 B=n/a C=13

In the example above part no 13 only has two real measurements, but part no 12 
has three real measurements, i need to be able to fill in the missing 
measurement with n/a. Please see below query set up.

!//Step 1: Get the product in question---


cfquery name=get_products datasource=#application.dsn#
SELECT products.productID, products.psubCatID, products.productName, 
products.productDescription
FROM products
WHERE productID = #prodID#
/cfquery


!---//Step 2: Get the related product parts and measurements---

cfquery name=get_meas datasource=#application.dsn#
SELECT pp.productPartID, pp.partProdID, pp.partNo, m.mTitle, m.measOne
FROM productPart pp INNER JOIN measurement m ON pp.productPartID = m.mPartID
WHERE pp.partProdID = #get_products.productID#
/cfquery

I think i need to set the query above to get the part no with the most amount 
of measurements, loop through the list and insert into other part numbers the 
missing measurements.

m.mtitle is used for A,B,C,D etc
m.measOne is used for the measurement

i.e mtitle=A measOne = 12

Any ideas

Jason

Jason Congerton
tel: +44 (0)1923 711605
mob: +44 (0)7811 250070


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328831
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Compare a Record and insert null values

2009-12-04 Thread Jason Congerton

Thanks for you response raj, however the column would not have been created at 
that point. If a user enters the first part no. with say three measurements 
a=1,b=2,c=4 that accounts for three rows against the specific part no., when he 
enters a second part no. with four measurements i.e. a=1,b=2,c=3,d=4.

I need the code to loop through all the part numbers, find the part no. with 
the most measurements assigned to it enter the missing value in all the part 
no. measurements.
i.e. 

part no.1 a=1,b=2,c=3,d=4,e=5
part no.2 a=1,b=2,c=3,d=4,e=5,e=6
part no.3 a=1,b=2,c=3

so part no 2 has the most measurements, now let’s update part no 1 and 3 with 
the same amount of measurements using the same title

i.e.

part no.1 a=1,b=2,c=3,d=4,e=5,e=n/a
part no.2 a=1,b=2,c=3,d=4,e=5,e=6
part no.3 a=1,b=2,c=3,d=n/a,e=n/a

I hope this explains it a little better.

Jason



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328872
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Compare a Record and insert null values

2009-12-04 Thread Jason Congerton

Hi 

I managed to acheive what i'm after, however its a seems bit intensive due to 
the loop factor, if there are any better ways i would love to hear them.



!//Step 1: Get the product in question---


cfquery name=get_products datasource=#application.dsn#
SELECT products.productID, products.psubCatID, products.productName, 
products.productDescription
FROM products
WHERE productID =  cfqueryparam value=#prodID# cfsqltype=cf_sql_integer
/cfquery


!---//Step 2: Get the related product parts and measurements---

cfquery name=get_meas datasource=#application.dsn#
SELECT pp.productPartID, pp.partProdID, pp.partNo, m.mTitle, m.measOne
FROM productPart pp INNER JOIN measurement m ON pp.productPartID = m.mPartID
WHERE pp.partProdID = #get_products.productID#
/cfquery

!---//Loop through the measurements---

cfloop query=get_meas

!---//Step 3: Get the all the measurement letters for every part no i.e 
a,b,c,d,e etc, 
using the in operator should return every letter used by the product part---

cfquery name=get_alpha datasource=#application.dsn#
SELECT tableLetter
FROM tableSort
WHERE tableLetter IN (SELECT mTitle
FROM measurement WHERE mPartID IN (SELECT productPartID
FROM productPart WHERE partProdID =  cfqueryparam 
value=#get_products.productID# cfsqltype=cf_sql_integer))
ORDER BY tableLetter ASC 
/cfquery

!---//Loop through the letters---

cfloop query=get_alpha

!---//Step 4: Find the missing letters looping through the get_alpha query for 
each part no---

cfquery name=get_final datasource=#application.dsn#
SELECT m.mTitle, m.mPartID
FROM measurement m 
WHERE m.mTitle = cfqueryparam cfsqltype=cf_sql_clob 
value=#get_alpha.tableLetter#  
AND m.mpartID = cfqueryparam cfsqltype=cf_sql_integer 
value=#get_meas.productPartID#
/cfquery

!---//Step 5: If the get_final query is empty, we know we can insert the 
letter and 0 values---

cfif get_final.recordcount EQ 0

cfquery name=ins datasource=#application.dsn#
INSERT INTO measurement (mtitle, measOne, mpartID)
VALUES (cfqueryparam cfsqltype=cf_sql_clob value=#get_alpha.tableLetter#, 
cfqueryparam cfsqltype=cf_sql_integer value=0,  cfqueryparam 
cfsqltype=cf_sql_integer value=#get_meas.productPartID#)
/cfquery


/cfif



/cfloop!---//get_alpha---



/cfloop!---//get_meas---






~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328887
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Compare records and update

2009-11-13 Thread Jason Congerton

Hi 

Just wondered if anyone had any ideas?

Jason






 Thank you again for your response, sorry for time its taking for me to 
 get my head around this!!
 
 Have a look at this
 
 http://tvpressings.jasoncongerton.co.uk/transteel-products/test.
 cfm?productid=2
 
 all looks good, however no NA in boxes with no measurements. however 
 this is only becauase the top two rows contains the top most amount of 
 measurements, all the way to T
 
 now look at this, i have placed the letters above the measurment to 
 show they are out of align with the top headers.
 
 http://tvpressings.jasoncongerton.co.uk/transteel-products/test.
 cfm?productid=29
 
 I need the ooutput to align with the top headers ABC.
 
 code below
 
 Jason
 
 
 !---get the measurements and parts no's---
 
 cfquery name=get_parts datasource=#application.dsn#

 SELECT p.lamNo,

   p.coreNo,

   p.pattern,

 p.productPartID, 

 p.partNo, 

 m.measOne,

 m.measTwo, 

 m.mTitle

 FROM productPart p INNER JOIN

 measurement m ON p.productPartID = m.mPartID
  
 WHERE p.partProdID = cfqueryparam value=#productID# 
 cfsqltype=cf_sql_integer 

 ORDER BY  p.order, p.lamNo, p.coreNo, p.pattern, m.mtitle
 /cfquery
 
 !---//get the letters for the top most row---
 
 cfquery name=get_alpha datasource=#application.dsn#
 SELECT tableLetter
 FROM tableSort
 WHERE tableLetter IN (SELECT mTitle
 FROM measurement WHERE mPartID IN (SELECT productPartID
 FROM productPart WHERE partProdID =  cfqueryparam value=#productID# 
 cfsqltype=cf_sql_integer))
 ORDER BY tableLetter ASC 
 /cfquery
 
 
 
 table
 tr
 td
 cfif get_parts.lamNo NEQ LAM NO:/cfifcfif get_parts.coreNo NEQ 
 CORE NO:/cfif
 cfif get_parts.pattern NEQ Pattern:/cfif/td
 tdstrongPART NO:/strong/td
 cfoutput query=get_alpha
 td style=width:70px; font-family:Verdana, Geneva, sans-serif; 
 font-size:10px; 
 text-align:center;strong#tableLetter#/strong/td
 /cfoutput
 /tr  
 cfoutput query=get_parts group=lamNo 
 td#lamNo#/td
 tdstrong#partNo#/strong/td
 cfset ctr = 0 /
 cfoutput group=mTitle
 td#mTitle#br /#decimalFormat(measOne)#cfif measTwo GT 0 X 
 #decimalFormat(measTwo)#/cfif/td
 cfset ctr = ctr+1 /
 /cfoutput
 cfif ctr lt get_alpha.recordcount
 cfloop from=#ctr# to=#get_alpha.recordcount# index=c
 tdnbsp;/td
 /cfloop
 /cfif
 
 /tr
 /cfoutput 

 
 /cfif

 

 
 /table
 
  
 
 
 

 /tr  
   
 

 
 
 

 

 cfoutput query=get_parts group=lamNo 

 

 td style=width:80px; font-family:Verdana, Geneva, sans-serif; 
 font-size:10px;strong#lamNo#/strong/td

 td style=width:80px; font-family:Verdana, Geneva, sans-serif; 
 font-size:10px;strong#partNo#/strong/td

 cfset ctr = 0 /

 cfoutput group=mTitle

 td style=width:70px; font-family:Verdana, Geneva, sans-serif; 
 font-size:10px; text-align:center;#mTitle#br 
 /#decimalFormat(measOne)#cfif measTwo GT 0 X 
 #decimalFormat(measTwo)#/cfif/td

 cfset ctr = ctr+1 /

 /cfoutput

 cfif ctr lt get_alpha.recordcount

 cfloop from=#ctr# to=#get_alpha.recordcount# index=c

 tdnbsp;/td

 /cfloop

 /cfif

 /tr

 /cfoutput 

 

 /cfif

 

 
 /table


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328386
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Compare records and update

2009-11-12 Thread Jason Congerton

Thank you again for your response, sorry for time its taking for me to get my 
head around this!!

Have a look at this

http://tvpressings.jasoncongerton.co.uk/transteel-products/test.cfm?productid=2

all looks good, however no NA in boxes with no measurements. however this is 
only becauase the top two rows contains the top most amount of measurements, 
all the way to T

now look at this, i have placed the letters above the measurment to show they 
are out of align with the top headers.

http://tvpressings.jasoncongerton.co.uk/transteel-products/test.cfm?productid=29

I need the ooutput to align with the top headers ABC.

code below

Jason


!---get the measurements and parts no's---

cfquery name=get_parts datasource=#application.dsn#
SELECT p.lamNo,
p.coreNo,
p.pattern,
p.productPartID, 
p.partNo, 
m.measOne,
m.measTwo, 
m.mTitle
FROM productPart p INNER JOIN
measurement m ON p.productPartID = m.mPartID
  WHERE p.partProdID = cfqueryparam value=#productID# 
cfsqltype=cf_sql_integer 
ORDER BY  p.order, p.lamNo, p.coreNo, p.pattern, m.mtitle
/cfquery

!---//get the letters for the top most row---

cfquery name=get_alpha datasource=#application.dsn#
SELECT tableLetter
FROM tableSort
WHERE tableLetter IN (SELECT mTitle
FROM measurement WHERE mPartID IN (SELECT productPartID
FROM productPart WHERE partProdID =  cfqueryparam value=#productID# 
cfsqltype=cf_sql_integer))
ORDER BY tableLetter ASC 
/cfquery



table
tr
td
cfif get_parts.lamNo NEQ LAM NO:/cfifcfif get_parts.coreNo NEQ CORE 
NO:/cfif
cfif get_parts.pattern NEQ Pattern:/cfif/td
tdstrongPART NO:/strong/td
cfoutput query=get_alpha
td style=width:70px; font-family:Verdana, Geneva, sans-serif; font-size:10px; 
text-align:center;strong#tableLetter#/strong/td
/cfoutput
/tr  
cfoutput query=get_parts group=lamNo 
td#lamNo#/td
tdstrong#partNo#/strong/td
cfset ctr = 0 /
cfoutput group=mTitle
td#mTitle#br /#decimalFormat(measOne)#cfif measTwo GT 0 X 
#decimalFormat(measTwo)#/cfif/td
cfset ctr = ctr+1 /
/cfoutput
cfif ctr lt get_alpha.recordcount
cfloop from=#ctr# to=#get_alpha.recordcount# index=c
tdnbsp;/td
/cfloop
/cfif
 /tr
/cfoutput 

/cfif


/table

  
 
/tr  



 

cfoutput query=get_parts group=lamNo 

td style=width:80px; font-family:Verdana, Geneva, sans-serif; 
font-size:10px;strong#lamNo#/strong/td
td style=width:80px; font-family:Verdana, Geneva, sans-serif; 
font-size:10px;strong#partNo#/strong/td
cfset ctr = 0 /
cfoutput group=mTitle
td style=width:70px; font-family:Verdana, Geneva, sans-serif; 
font-size:10px; text-align:center;#mTitle#br /#decimalFormat(measOne)#cfif 
measTwo GT 0 X #decimalFormat(measTwo)#/cfif/td
cfset ctr = ctr+1 /
/cfoutput
cfif ctr lt get_alpha.recordcount
cfloop from=#ctr# to=#get_alpha.recordcount# index=c
tdnbsp;/td
/cfloop
/cfif
/tr
/cfoutput 

/cfif


/table


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328295
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Compare records and update

2009-11-11 Thread Jason Congerton

Hi

I have a table which stores measurements, the measurements have a corresponding 
letter assoiciated with them i.e A = 0.34 B = 0.35 etc. 

Measurements are directly related to the productPart table. The productPart 
table stores part no info relating to the product and measurements.

One product main contain 1 or multiple part no's i.e

Product: UFC-SLOTTED
Part No: 21U, 22U, 23U, 24U

Each part number has it's own set of measurments i.e

Part No: 21U
Measurements: A=0.23, B=0.34, C=0.23

Part No: 22U
Measurements: A=0.23, B=0.34, C=0.23, D=0.45, E=0.46

As you can see the part numbers can use a varying amount of measurments, which 
is where my question comes. 

Part No: 21U has 3 measurments; A,B,C
Part No: 22U has 5 measuremnts; A,B,C,D,E

I need to fill the gaps automatically to produce the following and place NA or 
a null value.

Part No: 21U
Measurements: A=0.23, B=0.34, C=0.23, D=NA, E=NA, 

Part No: 22U
Measurements: A=0.23, B=0.34, C=0.23, D=0.45, E=0.46

Once the user has completed inserting the measurements for the part no, i will 
offer a button to finalise product insert.

I know i will need to loop around the the measurement table for each part no, 
but how do i know when to insert the correct title(i.e D) and the null value, 
what if statment will i use, i'm sure it must 

be possible. Table structure below;

productPart
productPartID(uid), partNo, lamNo

measurement
mID(uid),mPartID(link to productPart), mTitle, measOne

Thanks


Jason



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328263
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Compare records and update

2009-11-11 Thread Jason Congerton

Hi Robert

Thanks for your reply, although I'm not sure if I understand your response. 
Looking at the code you supplied, will this not just display NA if a is 
empty, my problem is a might not be even created.

part no 23a has 3 measurements: a=0.32,b=0.34,c=0.45
part no 24a has 2 measurements: a=0.12,b=0.43

for part no 24a, I would need to display c=na, although c does not exist for 
this part no. My final output should resemble this

Part NO: A BCD
23a  0.32  0.34 0.35 0.36
23a  0.32  0.34 NA   NA
23a  NA0.34 0.12 0.34

If I have misunderstood you - sorry.

Jason 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328279
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Output

2009-11-06 Thread Jason Congerton

 Hi Jason
 
 Thanks for your response, works great, just need to tidy up the output 
 and im done - thank you
 
 Jason 


Hi

If anyones interested heres the output link will be avaialable for a short time

http://tvpressings.jasoncongerton.co.uk/transteel-products/test.cfm?productid=2

Jason 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328084
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Output

2009-11-05 Thread Jason Congerton

Hi Jason

Thanks for your response, works great, just need to tidy up the output and im 
done - thank you

Jason 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328081
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Next and Previous on grouped output

2009-06-02 Thread Jason Congerton

Hi

I have query which joins together four tables, in my output i use group to 
display the correct information to the screen.

The query returns around 42 records of which 13 are being displayed to the 
screen, code below; (i'll tidy up .* when i get it working)

My question is how to do next and previous, my normal method falls short, 
because of the grouping as it uses the record count of the query to know where 
it is. 

I have had a look around for some examples, with no luck so far. If any one can 
pint me in the right direction - thank you.

cfquery name=get_global_products datasource=#application.dsn#
SELECT wp_products.*, gp_product_templates.*, wa_websites.*, wp_images.*
FROM ((gp_product_templates INNER JOIN wp_products ON 
gp_product_templates.gp_id = wp_products.wp_product_template_id) INNER JOIN 
wa_websites ON wp_products.wp_product_web_id = wa_websites.wa_websiteID) LEFT 
JOIN wp_images ON wp_products.wp_products_id = wp_images.wp_gp_product_id
WHERE wp_product_web_id = cfqueryparam cfsqltype=cf_sql_integer 
value=#get_websites.wa_websiteID# 
/cfquery

cfoutput query=get_global_products group=gp_name/cfoutput



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:323067
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Next and Previous on grouped output

2009-06-02 Thread Jason Congerton

Hi 

Thanks for you response, i downloaded and set up pagination.cfc, however this 
still uses the main query to get the total record count, when using with 
grouped ouput the wrong page amounts are retuned. However, i must say easy to 
use and setup!

Jason
Have you looked at this?
http://paginationcfc.riaforge.org/


On Tue, Jun 2, 2009 at 7:53 AM, Jason Congerton
ja...@jasoncongerton.co.ukwrote:

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:323082
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Data Import

2009-03-31 Thread Jason Congerton

Hi Sorry for such a late reply, thanks, worked a treat. better still the Mrs 
managed to do it!

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321117
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Data Import

2009-03-29 Thread Jason Congerton

Hi

My wife has brought home an excel spread sheet to create a mail merge, however 
the person who set up the data up has put the address in one column (albeit 
separated by commas i.e. 23 The Road, Somewhere, er2 3ry. I stupidly said now 
worries I can right a bit code which will import them to separate columns for 
you!

Should have made sure i know how to do it first! Well I think I do kind of.

I imported the data into a table called address, which has three columns

cname, address, tel. I have set up a table called newAddress with the following 
tables cname, add1, add2, add3, add4, add5, add6, add7 (as far as I can see the 
addresses are no longer than seven) As this is for a ms word mailmerge only, I 
do not need to specify town, postcode etc so the above columns will be fine.

I know i will have to query the old address and loop through them whilst 
looping through the address column, find the commas and insert it into the next 
available add field in the new table (not sure about this bit)

How can i insert the addresses in the next available column e.g.

Address 1 is 4 parts long so beginning with add1 insert upto add4
Address 2 is 6 parts long so beginning with add1 insert upto add6

I know i can use listlen to find the end of the addresses, but I’m not sure 
how to implement the insert statement. Will I need to use listgetat?

Any ideas are greatly appreciated

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321083
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Delivery Report

2009-03-25 Thread Jason Congerton

Hi 

I am trying to create a delivery report for my website, the report is generated 
from the following tables

ca_customers, ca_order_summary and ca_orderitems (please see query below)

ca_customer  holds the customer information (one record)

ca_order_summary  holds the order summary information (one record)

ca_order_items  contains the order items (multiple records)


cfquery name=get_orders datasource=#application.dsn#
SELECT c.*, os.*, oi.*
FROM (ca_customers c INNER JOIN ca_order_summary os ON c.ca_cust_id = 
os.ca_ordersum_cust_id) INNER JOIN ca_order_items oi ON os.ca_ordersum_id = 
oi.ca_orderitems_sum_id
WHERE 0=0
AND os.ca_ordersum_archived = cfqueryparam cfsqltype=cf_sql_bit value=no
AND os.ca_ordersum_invoiced = cfqueryparam cfsqltype=cf_sql_bit value=yes
AND os.ca_ordersum_delivered = cfqueryparam cfsqltype=cf_sql_bit value=no
cfif Isdefined('form.webID')AND c.ca_cust_web_id = cfqueryparam 
cfsqltype=cf_sql_integer value=#form.webID#/cfif
ORDER BY ca_ordersum_id DESC
/cfquery
(please note .* used for example)

I would like to produce a dynamic form which displays the orders one by one and 
also list the order items individually and have a check box next to the order 
items, 
so the user can decide which items from the order are included in a delivery 
report.


Order #1: Contains 5 items P1,P2,P3,P4,P5 The user would only like P3 to be 
included within the report.

I have handled dynamic forms before and have used the following format for my 
check boxes, and order summary id

input type=hidden name=ca_ordersum_id#currentrow# value=#ca_ordersum_id#
input type=hidden name=resCount 
value=cfoutput#get_orders.recordCount#/cfoutput
 input name=output#currentrow# type=checkbox class=boxes 
id=output#currentrow# value=yes  /


And use this type of code to create a list of id's to pass to a query, however 
this obviously just gets the ordersum id which will still include items I do 
not want. I can't be very far from what I need, just need a little help 
tweaking it.

Would I be better to build a 2d array i.e. order ID, product id if so could 
someone point me in the right direction with creating the array and accessing 
the array in the subsequent query to be produced.

cfset myList = 
cfloop index=i
from=1
to=#val(form.resCount)#

cfif StructKeyExists(Form,'ca_ordersum_id#i#')
   cfset variables.ca_ordersum_id = form['ca_ordersum_id#i#']/
cfif StructKeyExists(Form,'output#i#')
   cfset Variables.output = form['output#i#']/
   
  cfset myList = listappend(mylist, variables.ca_ordersum_id)
   

/cfif!---//end of variables output---

/cfif!---//end of variables ca_ordersum_id---

I hope this explains what I am trying to do, it does in my head anyway:-)

Kind Regards

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320907
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Delivery Report

2009-03-25 Thread Jason Congerton

Hi

Thank you for your replies, you are correct Azadi, I can not just have check 
boxes with the same name. 

I have resolved my issue in the following way,

I removed the group attribute from my initial form output which returned one 
row for each order item I added an orderitem_id#currentrow# hidden field, 
created two lists, one for orderid and one for the orderitems id, and used the 
IN operator on my query.

Which now returns the desired results!

I have one slight problem with the initial display, its a little messy. Lets 
say the customer has ordered three items, now that I have removed the 
grouping(so I can get at individual items) the customer name is returned 3 
times as well, can I use some conditions to stop this, or be able to group 
color the rows for the particular customer.

Jason




~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320942
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Read email contents and enter into database

2009-03-18 Thread Jason Congerton

Hi All

Thank you for all of your responses, i will post back with my results.

(Thanks for the code tony)

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320629
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Read email contents and enter into database

2009-03-17 Thread Jason Congerton

Hi

I have had look via google and found no answers, has anybody ever needed to 
read the contents of an email and enter them into a database.

The subject line will contain a unique identifier and emails will be fired into 
a single account.

I need to get the body contents and enter them into a database aginst the 
unique id in the subject line. 

I know i will need cfpop to read the mail, just not sure how to access the 
contents.

Many thanks

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320578
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Sales Report and Output

2009-03-13 Thread Jason Congerton

Hi

I need to do some reporting on orders from a web site, the table structure is 
as follows;

wp_products {ID: wp_products_id JOINED TO wp_products ON 
ga_product_templates.wp_product_template_id=wp_products.wp_product_template_id}

ga_product_templates{ID:gp_id; JOINED TO wp_products ON 
wp_products.wp_product_template_id=gp_product_templates.gp_id}

ca_order_items{ID:ca_orderitems_id; JOINED TO wp_products ON 
ca_order_items..ca_orderitems_product_id=wp_products.wp_products_id}

cfquery name=get_orders datasource=#application.dsn#
SELECT ca_order_items.*, wp_products.*, gp_product_templates.*
FROM ca_order_items INNER JOIN (gp_product_templates INNER JOIN wp_products ON 
gp_product_templates.gp_id = wp_products.wp_product_template_id) ON 
ca_order_items.ca_orderitems_product_id = wp_products.wp_products_id
ORDER by gp_name
/cfquery

(please note using .* for testing only)

I need to display the sales information per product e.g Product One: Sold 5 
Total: £500, Product Two: Sold 2 Total £350

I was thinking of using queries of queries but how do I get the individual 
product totals, apposed to the total of all the rows, etc. Do I need to loop 
around my first query, set a variable add it together and display to screen? 

Any ideas on the best way to approach this?

Thank you

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320507
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Sales Report and Output

2009-03-13 Thread Jason Congerton

Hi jason

Thanks for your reply, a few tweaks to my table names and it worked great!

Thank you!!!

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320513
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Join Problem

2009-03-07 Thread Jason Congerton

Hi 

I am joining two tables, together, there will always be one record in the left 
table associated to serveral in the right. When i query the tables, i always 
get to many records displayed. i.e if there are 5 items in the left table 
associated to 24 items in the right table instead of getting 5 rows i get 24. I 
applied a group on my cfoutput gp_name(unique) which makes it better but not 
right, here is my query

cfquery name=get_global_products datasource=#application.dsn#
SELECT gp_product_templates.gp_id, gp_product_templates.gp_name, 
gp_product_templates.gp_ref, gp_product_templates.gp_manf, 
gp_product_templates.gp_cat, gp_product_templates.gp_sub_cat, 
gp_product_templates.gp_length, gp_product_templates.gp_width, 
gp_product_templates.gp_height, gp_product_templates.gp_weight, 
gp_product_templates.gp_stock_qty, gp_product_templates.gp_accs, 
gp_product_templates.gp_stock_au, gp_product_templates.gp_stock_order_au, 
gp_product_templates.gp_stock_arrival_au, gp_product_templates.gp_stock_eu, 
gp_product_templates.gp_stock_order_eu, 
gp_product_templates.gp_stock_arrival_eu, gp_image_library.gp_image_id, 
gp_image_library.gp_image_name, gp_image_library.gp_image_url, 
gp_image_library.gp_image_description, gp_image_library.gp_image_product_id, 
gp_image_library.gp_website_name, gp_image_library.gp_image_type
FROM gp_product_templates INNER JOIN gp_image_library ON 
gp_product_templates.gp_id = gp_image_library.gp_image_product_id
/cfquery

cfqoutput query=thababove group=gp_name
/cfoutput

Any ideas

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320205
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Join Problem

2009-03-07 Thread Jason Congerton

Thanks for your responses

Sorry for my lack of question!!

The query grabs a product and its images, I only need to display products in 
the list I.e

product 1, product 2, product 3 etc.

At the moment the query will display product 1, product 1 etc for every picture 
it has, which I know is correct. 

Although my earlier posted query did not show it I had already tried order by 
and the group variable in cfoutput query. Which is normally how I would do 
this, but its not working, I do not even get a true representation of the 
images in the right table I.e if product 1 has four images, it may not 
necessarily display 4 times. I will have a poke around and post back.

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320214
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Mappings

2009-02-23 Thread Jason Congerton

Hi

My client is using a dedicated web server to host around five sites, to which I 
 have full control over the cf administrator. These entire sites utilise a 
shopping cart and all secure payments will be directed to one secure server i.e.

climbingframes.net.au payments to https://secure.selwoodproducts.com
climbingframesuk.com payments to https://secure.selwoodproducts.co.uk etc.

On the secure server (which resides on the same server) I will set up 
individual folders for each site to process the payments and customer info. 
These pages design wise, will have to mirror the referring site. 

Which is where my question comes, if I set up mappings can I use include files 
from say climbingframesuk.com on the secure.selwoodproducts.co.uk/cfuk address.

As stated above all these domains will all be on the same server.

Any pointer would be greatly appreciated, never really needed to get involved 
with the cf admin thing before.

Many thanks

Jason


Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319690
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Mappings

2009-02-23 Thread Jason Congerton

Hi 

Thanks for your replies!

The main reason for this is to include navigation files, so the page template 
stays intact on the secure part of the server, and am not intending using any 
cf code within these files. It's mainly so i have one point of update for 
navigation links.

I suppose i could use an iframe on the standard site and serve the forms to it, 
but people would have no way of knowing this was secure, and i will also need 
to share session variables between the two pages/sites? So creating the secure 
bits on the secure server is the best option i think? Any thoughts?

If only my client would pay for individual secure certs!

Jason



Yup, but be careful of any pages you intend to include with mappings which
rely on data created in its original app.

You also don't have to use mappings, you could use ExpandPath() to dot dot
slash your way to the files you need.

If you do find you have app specific vars in the included pages, consider
changing how you call them to customtag calls (cfmodule), then pass in the
data.

Adrian 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319713
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Arrays

2009-02-08 Thread Jason Congerton

Hi

I am currently getting trying to get my head arounds arrays. The shopping cart 
system i use, stores the cart details into an array. I need to be able to 
update the array with a figure at a certain point. Please see array structure 
below;

The place i need to enter is ITEMS, zone cost, drilled down by the item id.

i.e add zone cost to item array where ID EQ 12

I have had a look around, and i am thinking along the lines of array insert at?

Any help would be appreciated.

DecimalPlacesC 2  
DecimalPlacesW 2  
DiscountsDisplayIndex 1  
DisplayIndex 1  
ForceDecimalsC true  
ForceDecimalsW true  


Items array  
1 struct 
DeliveryCost 100.  
Description [empty string]  
FullDetails 1 The Cedar Ridge Playset (12)  
ID 12  
Name The Cedar Ridge Playset  
Price 651.304347826  
Quantity 1  
Ref SELWOOD-CEDARRIDGE-09  
TotalPrice 651.304347826  
TotalWeight 42  
Weight 42.00  
zoneCost 0.00  
 
2 struct 
DeliveryCost 50.  
Description [empty string]  
FullDetails 1 Cabin Package (18)  
ID 18  
Name Cabin Package  
Price 868.695652174  
Quantity 1  
Ref SELWOOD-CABIN-PCKG-09  
TotalPrice 868.695652174  
TotalWeight 130  
Weight 130.00  
zoneCost 0.00  
 
 
NumberDisplay 0  
Persistance 0  
SHIPPING array  
1 struct 
GetValue function WAEC_climbingframes_uk_Shipping_Charge 
Arguments: none 
ReturnType: Any
 
Roles:  
 
Access: public
 
Output:   
DisplayName:   
Hint:   
Description:   
 
 
IsActive true  
RuleName Shipping_Charge  
 
 
ShippingDisplayIndex 1  
ShippingIsTaxed true  
TAX array  
1 struct 
GetValue function WAEC_climbingframes_uk_VAT 
Arguments: none 
ReturnType: Any
 
Roles:  
 
Access: public
 
Output:   
DisplayName:   
Hint:   
Description:   
 
 
IsActive true  
RuleName VAT  
 
 
TaxDisplayIndex 1  
WeightAlign 1  
WeightSuffix oz  


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319036
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Arrays

2009-02-08 Thread Jason Congerton

Hi Matt

Thanks for the reply, you understood correctly. I will now have a play with 
your code and post my results. I kind of thought i would have to loop through 
the array, but could work out how to update, and at the right position.

Thank you

Hey Jason, if you don't already know which position in the array the
item id is located, then you'll need to loop through the array and
find it. Once found, you are actually dealing with a structure, so
updating is just a simple cfset. Something like this (assuming item id
is in session and new zoneCost coming from a form variable):

cfloop from=1 to=#arrayLen(Items)# index=i
  cfif Items[i].ID eq session.ID
cfset Items[i].zoneCost = form.zoneCost
  /cfif
cfloop

Does that make sense? I'm hoping I understand your question correctly.
Your post seemed to have a lot of extraneous info that I wasn't sure
if it was relevant.

-Matt

On Sun, Feb 8, 2009 at 5:36 AM, Jas
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319038
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Dynamic Form

2009-02-04 Thread Jason Congerton

I have created a dynamic form from a table in my database, delivery types. I 
insert the data using the code below

cfloop 
   index=LoopCount 
   from=1 
   to=#Val(form.ResCount)#
   
   cfif IsDefined(form.wp_select#Evaluate(LoopCount)#)
   cfset variables.wp_select=form.wp_select#Evaluate(LoopCount)#
   cfset variables.wp_select=#Evaluate(variables.wp_select)#
   cfelse
   cfset variables.wp_select=no
   /cfif
   cfset variables.wp_delivery_id=form.wp_delivery_id#Evaluate(LoopCount)#
   cfset variables.wp_delivery_id=#Evaluate(variables.wp_delivery_id)#
   cfset 
variables.wp_delivery_cost=form.wp_delivery_cost#Evaluate(LoopCount)#
   cfset variables.wp_delivery_cost=#Evaluate(variables.wp_delivery_cost)#

cfquery name=”insert_del” datasource=”#application.dsn#”
INSERT INTO del_cost (del_cost)
VALUES (cfqueryparam cfsqltype=cf_sql_integer value=#variables 
wp_delivery_cost #)

/cfloop

The above code quite rightly inserts a record for each row in my form, however 
I want it only to insert the row which has been selected. 

e.g. User has choice of Premium Delivery: £25.00, Basic Delivery £20.00, he 
selects a radio button next to Basic Delivery. Each delivery option has its own 
id, so differentiating them isn’t a problem; just can’t think how to single 
out the selected record.(mind you it is getting late!)

Thanks

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318905
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Dynamic Form

2009-02-04 Thread Jason Congerton

Hi Peter

Thanks worked a treat!

Jason
 You need to start by not doing this:
   cfif IsDefined(form.wp_select#Evaluate(LoopCount)#)
   cfset variables.wp_select=form.wp_select#Evaluate(LoopCount)#
   cfset variables.wp_select=#Evaluate(variables.wp_select)#
   cfelse
   cfset variables.wp_select=no
   /cfif
 
 Use bracket notation instead of the convoluted evaluate stuff.
 
 Something like this might do what you want:

 cfif StructKeyExists(Form,'wp_select#LoopCount#')

 cfset variables.wp_select = form['wp_select#LoopCount#'] /
 

 cfquery name=”insert_del” datasource=”#application.dsn#”

 INSERT INTO del_cost (del_cost)

 VALUES (cfqueryparam value=#form['wp_delivery_cost#LoopCount#']# 
 cfsqltype=cf_sql_integer)

 /cfquery
 

 /cfif
 
 
 (If that doesn't make sense, hopefully someone else can come along and 
 improve on the answer, because unfortunately I have to go sleep.)
 
 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318910
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Acces a record count in javascript

2009-02-03 Thread Jason Congerton

Hi

I need to access a recordcount from within a javascript function, is this 
possible?

script
function checkBoxValidate(cb) {
for (j = 0; j  RECORD COUNT OF QUERY TO GO HERE; j++) {
if (eval(document.addCust.ckbox[ + j + ].checked) == true) {
document.addCust.ckbox[j].checked = false;
if (j == cb) {
document.addCust.ckbox[j].checked = true;
 }
  }
   }
}
//  End --
/script

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318746
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Acces a record count in javascript

2009-02-03 Thread Jason Congerton

Hi Thanks to you all,

I was just missing the cfoutput tags!

Thanks!!

Jason,

It's important to remember that Javascript is commonly rendered AFTER
Coldfusion has compiled the page. This allows you to use Coldfusion to help
render such content.

Here is a basic request cycle to help show this:
Client makes request - Server proccess request (Coldfusion) - Server sends
back coldfusion rendered content - Client side scripting renders (example:
Javascript)

So as shown by the other posts you can output such things as recordsets to
the page to help dynamically generate the page.

-Pat
http://patweb99.avatu.com

On Tue, Feb 3, 2009 at 2:47 AM, Jason Congerton
ja...@jasoncongerton.co.ukwrote:

 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318759
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Insert from Dynamically Generated Form

2009-01-25 Thread Jason Congerton
Hi

I have created a form using a database table to supply the form fields; one of 
the fields is a check box, the other a text field. Please see code below,

form name=add_delivery method=post 
action=cfoutput#CurrentPage#/cfoutput

cfoutput query=get_delivery_types

input type=hidden name=ga_del_type_id#get_delivery_types.currentrow# 
value=#ga_del_type_id# /

input name=wp_delivery_active#get_delivery_types.currentrow# type=checkbox 
class=boxes id=wp_delivery_active#get_delivery_types.currentrow# 
value=yes  /

input type=text name=wp_delivery_cost#get_delivery_types.currentrow# 
id=wp_delivery_cost#get_delivery_types.currentrow# style=width:50px; 
value=#DecimalFormat(ga_del_guide_cost)# /
   
/cfoutput
input type=Hidden name=ResCount 
value=cfoutput#get_delivery_types.RecordCount#/cfoutput
input name=submit type=submit class=submitBtn id=submit value=Update 
Delivery Options style=margin:0px; /
   /form

I am using the following code to insert the record, however if all the check 
boxes are not checked, I get can not find form.wp_delivery_active3 error 
message. I know why I am getting this message, because the check box quite 
rightly does not exist if not completed. My question is, how do I create a cfif 
statement in the below code to specify no if form.wp_delivery_active3 is not 
present? I’ve tried a few, but to no avail.

cfloop 
   index=LoopCount 
   from=1 
   to=#Val(form.ResCount)#
   
   cfset variables.ga_del_type_id=form.ga_del_type_id#Evaluate(LoopCount)#
   cfset variables.ga_del_type_id=#Evaluate(variables.ga_del_type_id)#
 
   cfset 
variables.wp_delivery_active=form.wp_delivery_active#Evaluate(LoopCount)#
   cfset 
variables.wp_delivery_active=#Evaluate(variables.wp_delivery_active)#
  cfset 
variables.wp_delivery_cost=form.wp_delivery_cost#Evaluate(LoopCount)#
   cfset variables.wp_delivery_cost=#Evaluate(variables.wp_delivery_cost)#
  
 
 
 
 
 cfquery datasource=#application.dsn# name=updateProducts
 INSERT INTO  wp_delivery (wp_delivery_active, wp_delivery_detail, 
wp_delivery_product_id, wp_delivery_cost)
 VALUES (
  cfqueryparam cfsqltype=cf_sql_bit value=#Variables.wp_delivery_active#
, cfqueryparam cfsqltype=cf_sql_integer value=#variables.ga_del_type_id#
, cfqueryparam cfsqltype=cf_sql_integer value=#wp_products_id#
, cfqueryparam cfsqltype=cf_sql_integer 
value=#variables.wp_delivery_cost#)

  
  /cfquery
  
   /cfloop


Thanks

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318480
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Insert from Dynamically Generated Form

2009-01-25 Thread Jason Congerton
Hi

Can't believe I’ve been such a numpty, the isdefined statement I was trying 
had an error in the format missing bracket!! Corrected the bracket issue, works 
fine...

cfif IsDefined(form.wp_delivery_active#Evaluate(LoopCount)#)
cfset 
variables.wp_delivery_active=form.wp_delivery_active#Evaluate(LoopCount)#
cfset variables.wp_delivery_active=#Evaluate(variables.wp_delivery_active)#
cfelse
cfset variables.wp_delivery_active=no
/cfif

Kind Regards

Jason

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318482
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Aligning two tables

2008-11-27 Thread Jason Congerton
Hi

I am importing a spreadsheet into my database the spreadsheet contains client 
information and contact information. I need to enter these into two seperate 
tables one for client and one for contacts. 

Simplified excel layout is

clientid(newid), clientName, oldid, contactname

The oldid column links the contacts and clients together i.e

blank. ABC Ltd. 1055, Jason Congerton
blank, ABC Ltd, 1055, John Smith
blank, ABC Ltd, 1055, Angela Johns
blank, 123 Ltd, 1045, John Doe
blank, 123 Ltd, 1045, Alison Jones etc

I had to ipmport some data the other day and used the following type of query

cfquery name=insert datasource=#application.dsn#
INSERT INTO contacts (conclientlink, branchlocation, coaddress1, coaddress2, 
coaddress3, cocounty, copostcode, conposition, contacttel, contactemail, 
contactmobile, contactfax, contactfax, cfirstnames, csurname)
SELECT c.clientid, c.companyname, c.caddress1, c.caddress2, c.caddress3, 
c.ccounty, c.cpostcode, c.contactpos, c.contactphone, c.contactmail, 
c.contactmobile, c.contactfax, c.contactfirst, c.contactsurname
FROM clients.c INNER JOIN c.oldclientsid = c.oldclientsid

Having problems finishing the where statement, any ideas.

Thank you

Jason



 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:316008
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Aligning two tables

2008-11-27 Thread Jason Congerton
Hi 

Found a solution to this problem now,

stripped out the duplicate values i.e multiple contacts, added the non 
duplicate items to the clients table, created a temp table will all the 
contacts in and run the following query to get the data into the contacts table

cfquery name=insert datasource=#application.dsn#
INSERT INTO contacts (conclientlink, branchlocation)
SELECT c.clientid, cr.companyname 
FROM clients c INNER JOIN clients_r cr ON c.oldclientid = cr.oldclientid
/cfquery

Might be messy but it worked.

Jason


 Hi
 
 I am importing a spreadsheet into my database the spreadsheet contains 
 client information and contact information. I need to enter these into 
 two seperate tables one for client and one for contacts. 
 
 Simplified excel layout is
 
 clientid(newid), clientName, oldid, contactname
 
 The oldid column links the contacts and clients together i.e
 
 blank. ABC Ltd. 1055, Jason Congerton
 blank, ABC Ltd, 1055, John Smith
 blank, ABC Ltd, 1055, Angela Johns
 blank, 123 Ltd, 1045, John Doe
 blank, 123 Ltd, 1045, Alison Jones etc
 
 I had to ipmport some data the other day and used the following type 
 of query
 
 cfquery name=insert datasource=#application.dsn#
 INSERT INTO contacts (conclientlink, branchlocation, coaddress1, 
 coaddress2, coaddress3, cocounty, copostcode, conposition, contacttel, 
 contactemail, contactmobile, contactfax, contactfax, cfirstnames, 
 csurname)
 SELECT c.clientid, c.companyname, c.caddress1, c.caddress2, c.
 caddress3, c.ccounty, c.cpostcode, c.contactpos, c.contactphone, c.
 contactmail, c.contactmobile, c.contactfax, c.contactfirst, c.
 contactsurname
 FROM clients.c INNER JOIN c.oldclientsid = c.oldclientsid
 
 Having problems finishing the where statement, any ideas.
 
 Thank you
 
 Jason
 
 
 
 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:316009
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Wrong results in query

2008-11-26 Thread Jason Congerton
Hi John

Worked a treat! Correct results are now being returned. Thank you

Jason



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315958
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Wrong results in query

2008-11-26 Thread Jason Congerton
Hi

The query below returns the wrong results when the #keywords# criteria is used.

The query should return no more than 220 live vacancies, as all over vacancies 
have been archived. However, if you put in the #keywords# criteria other than 
all, the archive = no is completely ignored and 840 vacancies are returned.

Please see query below, i think my brackets are in the right places. Not sure 
on this one??


cfquery name=getVacs datasource=#application.dsn#
SELECT vacancies.vacid, vacancies.archive, vacancies.vdivisionid, 
vacancies.vtype, vacancies.postitle, vacancies.freetext, vacancies.actlocation, 
vacancies.vacdescrip, vacancies.benefits, vacancies.vuserid, vacancies.salary, 
vacancies.advertdate, vacancies.archivedate, vacancies.mailout, 
vacancies.sitesend, vacancies.viewcount, vacancies.applycount, 
vacancies.searchcount, vacancies.rate, vacancies.jobsend, vacancies.internal, 
vacancies.vreference, vacancies.vcontactEmail
FROM vacancies
WHERE (((vacancies.archive) = cfqueryparam cfsqltype=cf_sql_bit value=no) 
cfif Isdefined('divisionID') AND divisionID NEQ 'All'AND ((vdivisionID) = 
cfqueryparam cfsqltype=cf_sql_integer value=#divisionID#)/cfif
cfif IsDefined('vtype')AND ((vtype) = cfqueryparam cfsqltype=cf_sql_clob 
value=#vtype#)/cfif
cfif Isdefined('keyWords') AND keywords neq 'ALL' AND keywords neq ''
AND ((vacancies.postitle) LIKE cfqueryparam cfsqltype=cf_sql_clob 
value=%#Keywords#%)) 
OR (((vacancies.freetext) LIKE cfqueryparam cfsqltype=cf_sql_clob 
value=%#keyWords#%) 
OR ((vacancies.actlocation) LIKE cfqueryparam cfsqltype=cf_sql_clob 
value=%#keyWords#%)
OR ((vacancies.vacdescrip) LIKE cfqueryparam cfsqltype=cf_sql_clob 
value=%#keyWords#%) 
OR ((vacancies.benefits) LIKE cfqueryparam cfsqltype=cf_sql_clob 
value=%keywords%)/cfif)
ORDER BY advertdate DESC
/cfquery


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315956
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Data Import

2008-11-19 Thread Jason Congerton
Hi 

I have been given the task of importing some data from one database into 
another.

The data has been imported i now need to code the individual records.

I have three msaccess tables  candidates, cand_codings and search_criteria

In the candidates table is field called currentposition this holds the 
information i want to work with. 

The cand_codings table holds the position titles used in the new database.

Search_criteria tables holds, codingid (link to cand_coding), candidateID 
(links to candidates).

I some how need to loop through the candidate records, match the 
currentposition field to the cand_codings and insert into search_criteria the 
codingID  candidate id.

Not sure where to start at the moment, any ideas - thank you.

jason





~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315538
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Data Import

2008-11-19 Thread Jason Congerton
Thank you for all of your responses, i carried out the conversion using Jason's 
suggestion. Worked a treat! Thank you 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315606
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Bread Crumb

2008-11-13 Thread Jason Congerton
Hi 

I am trying to create a small now thrills dynamic breadcrumb for a site, how do 
i acces the title tags of a page? 

I was going to write my code to .cfm file and include it on all pages requiring 
breadcrumb trail.

I know you can use cfhttp to get the page title details, however, it seems 
having cfhttp request the same page it is on, times out.

Is ther any way of find out what the page title is, other than cfhttp?

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315203
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Post Code Check

2008-11-03 Thread Jason Congerton
I am trying to create a postal code and delivery cost app for my company,

I have set the tables up as 

tbl name au_zones: au_zone_id, au_zone(postal zone), au_basic(min cost), 
au_costpk(cost per kilo)
tbl name postCodes: post_code_id, postcode(postal code), pc_zoneid(link to 
au-zones)

tbl name products: productid, product_name, weight.

The calculation will come from postcode to zone 
au_basic+(au_costpk*product_weight)

The user will use a form with a text box for post code and a select box for 
products (multiples should be allowed).

When the user fills out and submits the form my products query will have 1 or 
multiple records, so i relise i will have to loop throught the query to get
the individual product weights. This is where my knowledge needs enlightening, 
how do i loop throught the query and and reference the weight against the
au_costpk field from for every product found, and then display it to the 
screen. Would i be on the right track using below?



cfloop query=qryName

cfset qryName.pdname  =  
(qryname.weight*otherqryname.au_costpk)+otherqryname.au_basic

/cfloop

Any ideas?

Thanks 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:314774
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Post Code Check

2008-11-03 Thread Jason Congerton
excellent, thank you very much. works a treat.
 Do it all in one query:
 
 SELECT p.product_name, 
 p.weight,
 (
 SELECT (z.au_basic + (z.au_costpk * p.weight))
 FROM au_zones z INNER JOIN
 postCodes c ON z.au_zone_id = c.pc_zone_id
 WHERE c.postcode = cfqueryparam= cfsqltype=CF_SQL_VARCHAR 
 value=#form.postalCode#
 ) AS deliveryCost
 FROM products p
 WHERE p.productid IN ( cfqueryparam cfsqltype=CF_SQL_VARCHAR 
 value=#form.productIDList# list=Yes )
 
 cfoutput query=queryName
 #product_name# [#weight# lbs]: $#deliveryCost# to ship
 /cfoutput
 
 That will give you a line for every selected product, with the name, 
 weight, and deliveryCost all computed in one query.
  I am trying to create a postal code and delivery cost app for my 
  company,
  
  I have set the tables up as 
  
  tbl name au_zones: au_zone_id, au_zone(postal zone), au_basic(min 
  cost), au_costpk(cost per kilo)
  tbl name postCodes: post_code_id, postcode(postal code), 
  pc_zoneid(link to au-zones)
  
  tbl name products: productid, product_name, weight.
  
  The calculation will come from postcode to zone 
  au_basic+(au_costpk*product_weight)
  
  The user will use a form with a text box for post code and a select 
 
  box for products (multiples should be allowed).
  
  When the user fills out and submits the form my products query will 
 
  have 1 or multiple records, so i relise i will have to loop throught 
 
  the query to get
  the individual product weights. This is where my knowledge needs 
  enlightening, how do i loop throught the query and and reference the 
 
  weight against the
  au_costpk field from for every product found, and then display it to 
 
  the screen. Would i be on the right track using below?
  
  
  
  cfloop query=qryName
  
  cfset qryName.pdname  =  (qryname.weight*otherqryname.
  au_costpk)+otherqryname.au_basic
  
  /cfloop
  
  Any ideas?
  
  Thanks 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:314789
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Mailer Output

2008-06-25 Thread Jason Congerton
that works thankyou!!
 On Tuesday 24 Jun 2008, Jason Congerton wrote:
  sorry I wasn't really clear with what I actually need help with, I
  basically need to know how to output the page html to a text file, I 
 have
  been looking at cfcontent.
 
 cfsavecontent
 #whateverMakesYourPage()#
 /cfsavecontent
 cffile action=write/
 
 
 -- 
 Tom Chiverton
 
 
 
 This email is sent for and on behalf of Halliwells LLP.
 
 Halliwells LLP is a limited liability partnership registered in 
 England and Wales under registered number OC307980 whose registered 
 office address is at Halliwells LLP, 3 Hardman Square, Spinningfields, 
 Manchester, M3 3EB.  A list of members is available for inspection at 
 the registered office. Any reference to a partner in relation to 
 Halliwells LLP means a member of Halliwells LLP.  Regulated by The 
 Solicitors Regulation Authority.
 
 CONFIDENTIALITY
 
 This email is intended only for the use of the addressee named above 
 and may be confidential or legally privileged.  If you are not the 
 addressee you must not read it and must not use any information 
 contained in nor copy it nor inform any person other than Halliwells 
 LLP or the addressee of its existence or contents.  If you have 
 received this email in error please delete it and notify Halliwells 
 LLP IT Department on 0870 365 2500.
 
 For more information about Halliwells LLP visit www.halliwells.com.


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308096
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Mailer Output

2008-06-24 Thread Jason Congerton
Hi 

My client is using a third party to send out there monthly email news letter, I 
have created an admin facility which creates the the mailer using full paths to 
images etc.. The email marketing software requires the user to copy and past 
the html source code into a form field.

For ease I would like to be able to output the queried page including all html 
to a text file, so the user can copy and paste, without the need to load the 
page, right click to view source etc. Or if there is a better way to go, I am 
all ears!!

Jason 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308032
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Mailer Output

2008-06-24 Thread Jason Congerton
Hi again

sorry I wasn't really clear with what I actually need help with, I basically 
need to know how to output the page html to a text file, I have been looking at 
cfcontent.

Jason



 Hi 
 
 My client is using a third party to send out there monthly email news 
 letter, I have created an admin facility which creates the the mailer 
 using full paths to images etc.. The email marketing software requires 
 the user to copy and past the html source code into a form field.
 
 For ease I would like to be able to output the queried page including 
 all html to a text file, so the user can copy and paste, without the 
 need to load the page, right click to view source etc. Or if there is 
 a better way to go, I am all ears!!
 
 Jason 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308036
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Left Join on 4 Tables

2008-06-03 Thread Jason Congerton
Hi

I need to query four tables and return all the results from the retailCustomer 
table regardless of matching records in retailOrders, retOrderItems and 
products. The innner join query i use is below (please note i will individually 
reference items in select stat. once i get this right, as well as using query 
params) I get errors when trying to create the left joins, any ideas?

Thanks

cfquery name=getCustomers2008 datasource=#application.dsn#
SELECT retailCustomer.*, retailOrders.*, retOrderItems.*, products.*
FROM products INNER JOIN ((retailCustomer INNER JOIN retailOrders ON 
retailCustomer.retailCustID = retailOrders.ocustID) INNER JOIN retOrderItems ON 
retailOrders.orderNo = retOrderItems.piOrderNo) ON products.productID = 
retOrderItems.piProductID
WHERE 0=0
cfif IsDefined('FORM.scCounty') AND FORM.scCounty NEQ 
AND (retCustCounty) LIKE '%#scCounty#%'/cfif
cfif IsDefined('FORM.scpdName') AND FORM.scpdName NEQ 1
AND (products.productID) = #scPdname#/cfif
/cfquery 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:306686
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Left Join on 4 Tables

2008-06-03 Thread Jason Congerton
Hi 

Thanks for your replys have tried the code and am getting the following error,

Syntax error (missing operator) in query expression 
'retailCustomer.retailCustID = retailOrders.ocustID LEFT JOIN retOrderItems ON 
retailOrders.orderNo = retOrderItems.piOrderNo LEFT JOIN products ON 
retOrderItems.piProductID = products.productID'. 

Tried troubleshooting but to no avail.

Jason


Try this. Note that if you use a where on one of the left joined
tables it kind of negates the left part of that. One way around this
is to add or x is null

FROM retailCustomer
LEFT JOIN retailOrders ON retailCustomer.retailCustID = retailOrders.ocustID
LEFT JOIN retOrderItems ON retailOrders.orderNo = retOrderItems.piOrderNo
LEFT JOIN products ON retOrderItems.piProductID = products.productID
WHERE 0=0
cfif IsDefined('FORM.scCounty') AND FORM.scCounty NEQ 
AND (retCustCounty) LIKE '%#scCounty#%'/cfif
cfif IsDefined('FORM.scpdName') AND FORM.scpdName NEQ 1
AND (products.productID) = #scPdname# OR products.productID IS NULL
/cfif


On Tue, Jun 3, 2008 at 4:15 AM, Jas
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:306697
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


looping through a form

2008-05-15 Thread Jason Congerton
Hi 

I posted a question a few weeks ago regarding looping through form results, and 
someone posted the code below for me to try, however no records are updated 
when the form is submited. In fact nothing is happening between the cfif 
findnocase(field, '_') statement. Any pointers?

Thanks

cfloop collection=#form# item=field
cfif findnocase(field, _)
cfset id = listgetat(field,2,'_')
cfset value = form[field]
!--- do whatever with id and value---
 cfquery datasource=#application.dsn# name=updateProducts
  Update products 
  Set price = #value#
  WHERE productID = #id#
 /cfquery
  
  /cfif
/cfloop 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:305305
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: looping through a form

2008-05-15 Thread Jason Congerton
thank you.it worked a treat.

The parameters to FindNoCase are back-to-front.

Adrian

Hi

I posted a question a few weeks ago regarding looping through form results,
and someone posted the code below for me to try, however no records are
updated when the form is submited. In fact nothing is happening between the
cfif findnocase(field, '_') statement. Any pointers?

Thanks

cfloop collection=#form# item=field
cfif findnocase(field, _)
cfset id = listgetat(field,2,'_')
cfset value = form[field]
!--- do whatever with id and value---
 cfquery datasource=#application.dsn# name=updateProducts
  Update products
  Set price = #value#
  WHERE productID = #id#
 /cfquery

  /cfif
/cfloop 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:305311
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Shopping Cart Delivery Charge

2008-05-15 Thread Jason Congerton
Hi

I am building a shopping cart which calculates shipping charges, some products 
also have an additional surcharge. Which is where i am stuck,

The additional surcharge is stored within the product table.

What i thought was to loop through the products in the cart,  query the 
products database to get the surcharge or surcharges, loop through the query 
results for the individual surcharges. If this is the correct way, how do i 
then add the surcharges up and account for when the loop finishes.

Jason



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:305363
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Shopping Cart Delivery Charge

2008-05-15 Thread Jason Congerton
The surcharge is for each product, you can only buy one main product at at time 
(multiple purchases are treated as trade), you can also add multiple 
accessories (which have no delivery charge) Shopping cart items are stored in 
the session. I am exploring the sum route at the moment.

Thank you all for your response. 



 Do you already have a query with your shopping cart? If so, just use a 
 query-of-query (with SUM()). You don't mention if the surcharge is by 
 product or by each item, but you may need to also be sure to factor in 
 the product quantity. 
 
 --- Mary Jo
 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:305375
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Update multiple Records

2008-05-02 Thread Jason Congerton
Hi

I need to update the price of multiple products using one form  i.e

Product  Price
ShoesUpdateable Text Field
Trainers Updateable Text Field
etc

I was going to name the text field newCost and loop through the list, but i 
obviously need to pass the id as well. Would it be best to name the text box 
with the id paramenter so each text box is unique? And then loop through the 
form results matching the id before inserting the form value??

Jason 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:304642
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Update multiple Records

2008-05-02 Thread Jason Congerton
Excellent thanks for the prompt responses

 Hi
 
 I need to update the price of multiple products using one form  i.e
 
 Product  Price
 ShoesUpdateable Text Field
 Trainers Updateable Text Field
 etc
 
 I was going to name the text field newCost and loop through the list, 
 but i obviously need to pass the id as well. Would it be best to name 
 the text box with the id paramenter so each text box is unique? And 
 then loop through the form results matching the id before inserting 
 the form value??
 
 Jason 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:304650
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Update multiple Records

2008-05-02 Thread Jason Congerton
Hi All

Sorry i think i  am being a bit thick here!! but how do i get the id from the 
form name as i can only access the value of the form field in my action page.

Jason

 Hi
 
 I need to update the price of multiple products using one form  i.e
 
 Product  Price
 ShoesUpdateable Text Field
 Trainers Updateable Text Field
 etc
 
 I was going to name the text field newCost and loop through the list, 
 but i obviously need to pass the id as well. Would it be best to name 
 the text box with the id paramenter so each text box is unique? And 
 then loop through the form results matching the id before inserting 
 the form value??
 
 Jason 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:304671
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: xmlParse

2008-04-15 Thread Jason Congerton
Thank you for your replies, the xml is from an external source however i have 
some control over the formatting and will see if we can do the CDATA.

Thank you 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303381
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


xmlParse

2008-04-14 Thread Jason Congerton
Hi 
I have built a page which receives a http post in xml format, which then adds a 
record to the database. I am using xmlParse to read the contents of the file, 
however this seems to be removing the line breaks br / from the description 
field of the xml  i have tried entering using xmlFormat with no luck. How can i 
keep the line breaks intact. the code used to get the data is

!---//Get the http post data---
cfset docContent = GetHTTPRequestData()

!---//Parse the XML document, using trim to ensure valid content ---

cfset mydoc = XmlParse(docContent.content)

i call the xml nodes like this

#mydoc.plexis_vacancy.job.job_reference.XmlText#

Any help would be appreciated.

Jason


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303336
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Drill Down Problem

2008-02-11 Thread Jason Congerton
Thank you for your response, i ended up using an iif statment in the end, which 
gives the same results as your solution, please see below

AND (((iif(products.cfsalePrice=0, 
products.rrPrice,products.cfsalePrice))=1000))

Thanks

I haven't tested, but maybe something like this?

SELECT productType.*, productRange.*, products.*,
   Displayprice = CASE products.cfsalePrice
 WHEN products.cfsalePrice = 0 THEN products.rrPrice
  ELSE products.cfsalePrice
END
FROM (productType, productRange, products
WHERE productType.prodtypeID = productRange.prpdType
AND productType.prodtypeID = products.pdType
AND productRange.prID = products.pdRange) 
AND Displayprice = 1000

William
-- 
William E. Seiter
 
Have you ever read a book that changed your life?
Go to: www.winninginthemargins.com
Enter passkey: goldengrove
 
Web Developer / ColdFusion Programmer
http://William.Seiter.com
Hi

I am working on a product database, and need to drill down the products
using price bands i.e. upto £1000, £1001 to £2500 etc.

My problem is; the database table has two fields for pricing info, an RRP
and a sale price. The RRP price has to stay intact and can not be changed to
the sale price. (If the product is not on offer the sale price field remains
at £0.00.) If i use the following clause i get all the products, quite
rightly as the sale price field is less than 1000

AND (((products.rrPrice)=1000)) OR (((products.cfsalePrice)=1000))

so i added this

AND (((products.cfsalePrice)  0))

This now returns all products with an RRP less than 1000, great!! However,
this will not return a product with a sale price of £800, and a RRP of
£1250, which is right!! Because the RRP is greater than 1000, but i need it
to return the on sale products as well, regardless that the RRP is still
higher than 1000. I hope this make sense. Any help would be appreciated.


Full query below;

cfquery name=getProducts datasource=#application.dsn#
SELECT productType.*, productRange.*, products.*
FROM (productType INNER JOIN productRange ON productType.prodtypeID =
productRange.prpdType) INNER JOIN products ON (productType.prodtypeID =
products.pdType) AND (productRange.prID = products.pdRange)
WHERE 0=0 AND (products.pdArchive) = 0
AND (((products.rrPrice)=1000)) OR (((products.cfsalePrice)=1000))
AND (((products.cfsalePrice)  0))
/cfquery

Jason

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:298700
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Drill Down Problem

2008-02-10 Thread Jason Congerton
Hi

I am working on a product database, and need to drill down the products using 
price bands i.e. upto £1000, £1001 to £2500 etc.

My problem is; the database table has two fields for pricing info, an RRP and a 
sale price. The RRP price has to stay intact and can not be changed to the sale 
price. (If the product is not on offer the sale price field remains at £0.00.) 
If i use the following clause i get all the products, quite rightly as the sale 
price field is less than 1000

AND (((products.rrPrice)=1000)) OR (((products.cfsalePrice)=1000))

so i added this

AND (((products.cfsalePrice)  0))

This now returns all products with an RRP less than 1000, great!! However, this 
will not return a product with a sale price of £800, and a RRP of £1250, which 
is right!! Because the RRP is greater than 1000, but i need it to return the on 
sale products as well, regardless that the RRP is still higher than 1000. I 
hope this make sense. Any help would be appreciated.


Full query below;

cfquery name=getProducts datasource=#application.dsn#
SELECT productType.*, productRange.*, products.*
FROM (productType INNER JOIN productRange ON productType.prodtypeID = 
productRange.prpdType) INNER JOIN products ON (productType.prodtypeID = 
products.pdType) AND (productRange.prID = products.pdRange)
WHERE 0=0 AND (products.pdArchive) = 0
AND (((products.rrPrice)=1000)) OR (((products.cfsalePrice)=1000))
AND (((products.cfsalePrice)  0))
/cfquery

Jason




~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:298668
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Pskill and cfexecute

2008-01-27 Thread Jason Congerton
  I am trying to kill the process htmldoc.exe, using pskill.exe, 
 however 
  i keep getting the following error
 
 It might be waiting for acceptance of the EULA. If you are using a 
 newer version, try adding the flag -accepteula 


it did appear, and i replied, which doesn't look like it loaded either, you fix 
worked a treat - thank you, have been pulling me hair out 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:297540
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Pskill and cfexecute

2008-01-26 Thread Jason Congerton
Hi

I am trying to kill the process htmldoc.exe, using pskill.exe, however i keep 
getting the following error

Timeout period expired without completion of E:\Websites\pstools\pskill.exe  
 
  
The error occurred in E:\Websites\selwood\test1.cfm: line 7
 
5 : 
6 : 
7 : cfexecute name=#pSkill# arguments=-t htmlDoc outputfile=#psfile# 
timeout=25/cfexecute


Here is my code

cfset pskill = E:\Websites\pstools\pskill.exe
cfset psdir = E:\Websites\pstools\
cfset psfile = E:\Websites\pstools\ps.txt

cfexecute name=#pSkill# arguments=-t htmlDoc outputfile=#psfile# 
timeout=25/cfexecute

any help would be appreciated

jason


 


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:297514
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Pskill and cfexecute

2008-01-26 Thread Jason Congerton
  I am trying to kill the process htmldoc.exe, using pskill.exe, 
 however 
  i keep getting the following error
 
 It might be waiting for acceptance of the EULA. If you are using a 
 newer version, try adding the flag -accepteula 

good job!!! i've been yanking my hair on this one, tried permissions, different 
file locations, timeouts, different solutions - thank you!!! 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:297535
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Dynamically populate a select box within a PDF form.

2007-06-15 Thread Jason Congerton
 I'm not sure if this is possible, and have been looking for 
 examples without luck. One of my clients have requested the 
 ability to post products to their website via a PDF form. My 
 question is, can I dynamically populate a select box on the 
 PDF form from the websites database. Would this be possible 
 by creating a web service and linking the PDF form to it? If 
 any one has had experience of this, I would greatly 
 appreciate your help.

Yes, you can. You will have to create your PDF using LiveCycle Designer,
which is bundled with Acrobat Professional. You can invoke web services from
XFA-compliant PDFs (LiveCycle Designer creates these). If you're writing the
web service in ColdFusion, you will need to publish your service as
document/literal rather than rpc/encoded. I think this requires CF 7 or
7.0.1, I forget which:

cfcomponent style=document

Within your PDF, you will have to create a data binding to the WSDL file of
your service, then bind the drop-down box field to the response object
corresponding to your web service call. To initiate the request, you can use
a button and hook the request to it, then set the button to control type
Execute. Alternatively, you can execute your web service request using
JavaScript and the appropriate XFA DOM event handler - off the top of my
head, I have no idea what that would be. You'll want to read the topic
Executing a web service operation in the Adobe LiveCycle Designer Help.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

This email has been processed by SmoothZap - www.smoothwall.net

Thanks Dave, i now have the data connection within the form, just need to 
workout how to bind the select box to my query now. This is all new for me, 
have not needed to use the web service before. 

jason

~|
Upgrade to Adobe ColdFusion MX7
The most significant release in over 10 years. Upgrade  see new features.
http://www.adobe.com/products/coldfusion?sdid=RVJR

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:281232
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Dynamically populate a select box within a PDF form.

2007-06-15 Thread Jason Congerton
Hi All

Still got a few problems with dynmaically populating the select box, 

I have connected the PDF form to the web service, which is now available from 
within the form. My qestion is how do i bind to the drop down list? My web 
service code is below for perusal. I have outputed the query results to an 
array (tested with cfdump all is ok) results as expected, i just can not figure 
out how to access them via the PDF form. Any Ideas!!


!---//We need to publish this service as document/literal rather than 
rpc/encoded---
cfcomponent style=document

!---//Set-up the function allowing remote access---

cffunction name=productType access=remote returntype=array output=true

!---//Query the product type database for a list of Product Types---

cfquery name=getType datasource=hurley
SELECT productType, pTypeID
FROM productType
/cfquery

!---//Create an array to output to the web client---

cfset returnArray=ArrayNew(2)

!--- Populate the array row by row ---
cfloop query=getType

cfset returnArray[CurrentRow][1]=productType
cfset returnArray[CurrentRow][2]=pTypeID

/cfloop

cfreturn returnArray

/cffunction

/cfcomponent

~|
ColdFusion 8 beta – Build next generation applications today.
Free beta download on Labs
http://www.adobe.com/cfusion/entitlement/index.cfm?e=labs_adobecf8_beta

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:281318
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Dynamically populate a select box within a PDF form.

2007-06-14 Thread Jason Congerton
Hi

I'm not sure if this is possible, and have been looking for examples without 
luck. One of my clients have requested the ability to post products to their 
website via a PDF form. My question is, can I dynamically populate a select box 
on the PDF form from the websites database. Would this be possible by creating 
a web service and linking the PDF form to it? If any one has had experience of 
this, I would greatly appreciate your help.

~|
Create robust enterprise, web RIAs.
Upgrade  integrate Adobe Coldfusion MX7 with Flex 2
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJP

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:281156
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Inserting two records

2002-07-04 Thread Jason Congerton - RedHedNet

Hi All

I am using CF5 and msaccess97 the server sits on a Windows 2000 platform.
When using the following code the database inserts two identical records
(all but the uniquieid) I have used debug and the insert stament in not
looping - it's driving me insane. I have heard this may be a bug? Dose
anyone else know?

Regards

Jason

!-// set todays date---
cfparam name=ldate default=#DateFormat(now(),dd-mmm-)#

!---//lock the code to retreive the last entered id---

cflock name=insertinto type=exclusive timeout=30

!//check to see how many lists are already saved for this user, and
redirect them if
they have more than six//
cfquery name=getlist datasource=#application.dsn#
SELECT *
FROM
save_list
where luserid = #session.id#
/cfquery
cfif getlist.recordcount LT 6


!-//if the user has less than six saved lists, save the new
list//


cfquery name=insert datasource=#application.dsn#
INSERT INTO save_list (ldate, lname, list, luserid)
VALUES ('#ldate#', '#lname#', '#selected#', #session.id#)
/cfquery

!-//get that last saved list id for the re-direct//--

cfquery name=getmax datasource=#application.dsn#
SELECT max(listid) as id
FROM save_list
/cfquery

!--//now the list is saved delete the temporary search list//

cfquery name=delete datasource=#application.dsn#
DELETE FROM searchlist
where userlink = #session.id#
/cfquery
!now re-direct the user to saved list//--
cfoutput
script language=JavaScript
setTimeout(window.location ='saved_results.cfm?id=#getmax.id#', 5000);
/script
/cfoutput

!--//if the user already has six saved lists, re-direct them and ask
them to overwrite one of the existing

cfelse

cflocation
url=over_ten.cfm?selected=#selected#urlname=#form.lname#ldate=#ldate#
/cfif


/cflock





This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: Inserting two records

2002-07-04 Thread Jason Congerton - RedHedNet

No custom tag is being used, just a straight forward insert
statement...aghhh

-Original Message-
From: S. Isaac Dealey [mailto:[EMAIL PROTECTED]]
Sent: 04 July 2002 15:52
To: CF-Talk
Subject: Re: Inserting two records


The only other thing I would check is if this might be running in a custom
tag and does the tag have an end-tag ( even if it wasn't intended to have an
end-tag ) ... based on the code I'm guessing it's not in a custom tag 'cause
I don't see any references to the attributes scope though that's not an
absolute qualifier... but if you have it in a custom tag and have somehow
inadvertently applied an end tag, i.e. something like this:

cfmodule template=...
cfmodule template=...
/cfmodule

or similar could cause an inadvertent ending of a custom tag in which case
you could possibly get the code running twice...

Isaac

www.turnkey.to
954-776-0046

 Hi All

 I am using CF5 and msaccess97 the server sits on a Windows
 2000 platform.
 When using the following code the database inserts two
 identical records
 (all but the uniquieid) I have used debug and the insert
 stament in not
 looping - it's driving me insane. I have heard this may be
 a bug? Dose
 anyone else know?

 Regards

 Jason

 !-// set todays date---
 cfparam name=ldate
 default=#DateFormat(now(),dd-mmm-)#

 !---//lock the code to retreive the last entered
 id---

 cflock name=insertinto type=exclusive timeout=30

 !//check to see how many lists are already saved for
 this user, and
 redirect them if
 they have more than six//
 cfquery name=getlist datasource=#application.dsn#
 SELECT *
 FROM
 save_list
 where luserid = #session.id#
 /cfquery
 cfif getlist.recordcount LT 6


 !-//if the user has less than six saved lists, save
 the new
 list//


 cfquery name=insert datasource=#application.dsn#
 INSERT INTO save_list (ldate, lname, list, luserid)
 VALUES ('#ldate#', '#lname#', '#selected#', #session.id#)
 /cfquery

 !-//get that last saved list id for the
 re-direct//--

 cfquery name=getmax datasource=#application.dsn#
 SELECT max(listid) as id
 FROM save_list
 /cfquery

 !--//now the list is saved delete the temporary
 search list//

 cfquery name=delete datasource=#application.dsn#
 DELETE FROM searchlist
 where userlink = #session.id#
 /cfquery
 !now re-direct the user to saved list//--
 cfoutput
 script language=JavaScript
 setTimeout(window.location
 ='saved_results.cfm?id=#getmax.id#', 5000);
 /script
 /cfoutput

 !--//if the user already has six saved lists,
 re-direct them and ask
 them to overwrite one of the existing

 cfelse

 cflocation
 url=over_ten.cfm?selected=#selected#urlname=#form.lname#
 ldate=#ldate#
 /cfif


 /cflock





 This e-mail and any files transmitted with it are
 confidential and
 intended solely for the use of the individual or entity to
 whom they
 are addressed. If you have received this email in error
 please notify
 [EMAIL PROTECTED]

 Whilst every endeavour is taken to ensure that e-mails are
 free from
 viruses, no liability can be accepted and the recipient is
 requested
 to use their own virus checking software.


 __
 
 Your ad could be here. Monies from ads go to support these
 lists and provide more resources for the community.
 http://www.fusionauthority.com/ads.cfm
 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
 Archives:
 http://www.mail-archive.com/cf-talk@houseoffusion.com/
 Unsubscribe:
 http://www.houseoffusion.com/index.cfm?sidebar=lists




__
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: Inserting two records

2002-07-04 Thread Jason Congerton - RedHedNet

Sorry already tried that, I might try the final option in a minute and
launch my pc out the nearest available window!!!

-Original Message-
From: Alex [mailto:[EMAIL PROTECTED]]
Sent: 04 July 2002 17:05
To: CF-Talk
Subject: RE: Inserting two records


  cfquery name=insert datasource=#application.dsn#
  INSERT INTO save_list (ldate, lname, list, luserid)
  VALUES ('#ldate#', '#lname#', '#selected#', #session.id#)
  /cfquery

Where are these values coming from? Prefix them like #form.value# and
see what happens.



__
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Outlook Appointment

2002-06-27 Thread Jason Congerton - RedHedNet

Dear All

I need to be able to add an appointment to Outlook on the user machine not
the server is this possible with COM?

Jason 


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Outlook Appointment

2002-06-27 Thread Jason Congerton - RedHedNet

Dear All

I need to be able to add an appointment to Outlook on the user machine not
the server is this possible with COM?

Jason 


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Com Help!

2002-06-13 Thread Jason Congerton - RedHedNet

Hi

I'm new to com! And would like to know if the following is achievable.  I am
constructing a recruitment database, which holds cv's i need to be able to
open the cv within the browser, allow changes to be made and then save it
back to the server.  If this is possible could someone point me in the right
direction??

Kind Regards

Jason Congerton 


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



CF Content

2002-06-08 Thread Jason Congerton - RedHedNet

Hi All
 
I am constructing a recruitment database, which will hold cv's in word
format.  I have created a cf content template so the cv is viewable in word
format, however if the user changes the cv and then wishes to save the
alterations they are prompted for a location, which will point to there
local machines.  I need to create a button which saves the cv back to the
server.  Any Ideas??
 
Kind regards
 
Jason


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Check for table existence??

2002-05-22 Thread Jason Congerton - Mcaonline

Dear ALL

 
A bit new to all this..

Can you check to see if a table exists within a database with cold fusion?
If so can someone tell me how please.

The reason for this, is one part of my database copies a table into another
which is name uniquley by a the users id, however this table needs to be
deleted once the user has logged off, problem being if the user does not log
off correctly the table will still be there, so I need to be check for
existence and delete at the logon stage.

Regards


Jason


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.


__
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: Check for table existence??

2002-05-22 Thread Jason Congerton - Mcaonline

The cftry works a treat.  thank you 

-Original Message-
From: Justin Hansen [mailto:[EMAIL PROTECTED]]
Sent: 22 May 2002 14:21
To: CF-Talk
Subject: RE: Check for table existence??


This query will return a list of tables in your datasource.

cfquery name=qryTables datasource=#locDatasource#
SELECT TABLE_NAME
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_TYPE = 'BASE TABLE'
AND TABLE_Name  'dtproperties'
/cfquery

Justin Hansen
--
Uhlig Communications
Web Developer / Programmer
--
[EMAIL PROTECTED]
913-754-4273
--


-Original Message-
From: Jason Congerton - Mcaonline
[mailto:[EMAIL PROTECTED]]
Sent: Wednesday, May 22, 2002 7:52 AM
To: CF-Talk
Subject: Check for table existence??


Dear ALL


A bit new to all this..

Can you check to see if a table exists within a database with cold fusion?
If so can someone tell me how please.

The reason for this, is one part of my database copies a table into another
which is name uniquley by a the users id, however this table needs to be
deleted once the user has logged off, problem being if the user does not log
off correctly the table will still be there, so I need to be check for
existence and delete at the logon stage.

Regards


Jason


This e-mail and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
[EMAIL PROTECTED]

Whilst every endeavour is taken to ensure that e-mails are free from
viruses, no liability can be accepted and the recipient is requested
to use their own virus checking software.




__
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists