I had to tie an app into a UNIX password file once, kind of the same thing.

We used CFHTTP and a Perl script to validate the users submitted login
data against the password file. We also used a Perl script and CFHTTP
calls to submit new users, edit the ones already there, and so on. If
we needed to get a list of data back (which also was required for
other parts of the app) we'd use Perl to create a comma-delimited
dblequote-escaped column/row set in conjunction with the CFHTTP query=
attribute. Worked pretty well.

If that won't work, I'm guessing you could use about any method you
wanted to for hitting this text file... you shouldn't HAVE to use
ODBC. The real question is how are you accessing it... via the file
system, remotely, via a URL? The .cgi extension kinda makes me wonder
what's up. Is this file being created by another web server process?

Laterz,
J


On Wed, 09 Feb 2005 06:03:24 -0400, cf coder
<[EMAIL PROTECTED]> wrote:
> Hi,
> 
> Just wondering if anyone has experience with using the Microsoft Text ODBC 
> Driver with Coldfusion?
> 
> The problem I am getting is that the datasource I have to work with is named 
> "account.dat.cgi".
> 
> I have set up a System DSN on the server for the folder containing this file, 
> and configured it so that the ODBC manager finds all the columns and have set 
> all the datatypes.  All looks fine.  I should note that when I originally did 
> this I got an error, as detailed in this MS Support article:
> 
> http://support.microsoft.com/?id=304206
> 
> I took the third option they detail, namely to add both "dat" and "cgi" to 
> the registry entry - and this cured the problem.
> 
> Next I added the ODBC DSN into the ColdFusion datasources.
> 
> However, when I wrote a short CF script to query this datasource, I got the 
> below error:
> 
> Error Executing Database Query.
> [Macromedia][SequeLink JDBC Driver][ODBC Socket][Microsoft][ODBC Text Driver] 
> The Microsoft Jet database engine could not find the object 
> 'account.dat.cgi'. Make sure the object exists and that you spell its name 
> and the path name correctly.
> 
> The error occurred in E:\inetpub\wwwroot\artman_dev\Coldfusion\admin.cfm: 
> line 21
> 
> 19 : <cfquery name="getAccount" datasource="articleManager">
> 20 : select * from account.dat.cgi
> 21 : where LCASE(USERLOGINID) = 
> '<cfoutput>#LCASE(session.user.username)#</cfoutput>'
> 22 : </cfquery>
> 
> The first thing I suspected was that ColdFusion hasn't allowed me to query 
> the .dat or .cgi file types despite the setup in the ODBC.  To that end I 
> made a duplicate of "account.dat.cgi" and renamed it "account.txt".  After 
> updating my script to query the new file, everything worked fine.
> 
> So, does anyone know of a way I can get ColdFusion to query the original 
> file?  Or perhaps a different method entirely?  The file is used for the user 
> account data for an application we use, and the application does not allow 
> very good user account management, so I've been asked to write a couple of 
> ColdFusion scripts that will allow users to create/modify/delete new accounts?
> 
> Regards,
> 
> cfcoder
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193912
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to