Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

multiple cfx_excel tags to parse different sections of excel spreadsheet?

Posted on 2008-10-15
1
Medium Priority
?
515 Views
Last Modified: 2013-12-20
we are creating a CF applicaiton to load an excel expense report into an access db using the CFX_EXCEL tag we bought from /www.masrizal.com.  In the Excel spreadsheet, the first xnumber of columns and rows are reserved for details about the employee, employee name, id #, etc.  The next xnumber of columns and rows are for specifcs on the expense - date, incurred, cost center #, meals amount, auto amount, airfare amount, etc.  I need to submit the employee information in one table and the expense information into a seperate table in an Access db.  The CFX_Excel tag seems either parse all of the data into one large output or I can seperate the data as I have done with modifying the values to be specific for one section, but then I am only returning one section of the sheet and not he other.  I am a novice with CF but any help is appreciated.
<cfx_excel action="read" 
										File="#prodThumbDir#/#prodThumbFile#"
										Sheet= "1"
										Result="qryResult"
										Formula="process"
										StartRow="5"
										EndRow="17"
										StartCol="A"
										EndCol="0"
										HeaderRow="4"
										ProcessMerged="True"
										DecimalDigit="2">

Open in new window

0
Comment
Question by:dbarnes2
1 Comment
 
LVL 63

Accepted Solution

by:
Zvonko earned 2000 total points
ID: 22761913
I assume what you get from that cfx_excel is a table liek from a cfquery.
Now you can use that one result table to do the next cfqueries with dbtype set to query.
Like this:
<cfx_excel action="read" 
 File="#prodThumbDir#/#prodThumbFile#"
 Sheet= "1"
 Result="qryResult"
 Formula="process"
 StartRow="5"
 EndRow="17"
 StartCol="A"
 EndCol="0"
 HeaderRow="4"
 ProcessMerged="True"
 DecimalDigit="2">
 
<cfquery name="tblEmployee" dbtype="query" >
  SELECT col1, col2, col3 from qryResult
</cfquery>
 
<cfquery name="tblExpense" dbtype="query" >
  SELECT col4, col5, col6 from qryResult
</cfquery>

Open in new window

0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
What You Need to Know when Searching for a Webhost Provider
The purpose of this video is to demonstrate how to insert an Iframe into WordPress. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php : Open Page or Post…
The purpose of this video is to demonstrate how to manually back up a WordPress Database. This will be demonstrated using a Windows 8 PC. The Host used will be IPage.com Log into your Hosting account. IPage will be used for demonstration : Locat…
Suggested Courses

782 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question