Ask a Question related to Coldfusion Database Access, Design and Development.
-
Dinghus #1
Printing database fields
Okay, stuck with CF4.5. No biggy. I just want to pull data from a db and make
an xml file out of it. BUT I want it to be generic and fast. to code.
I know by the time I get an answer I could have it coded the long way so this
is for future reference.
What I want to do is run my query then do something like this:
<MYXML>
<cfoutput query="myQuery">
<OUTPUT #fieldname#="#db data#">
</cfoutput>
So how do I get the field name from the query or can I? Pretty sure I've seen
it done before.
Dinghus Guest
-
font missing shows during printing of forms fields
To use interactive form fill I scanned my existing form and used as a watermark in the background and create an interactive form fields on top of it... -
Inserting value into database based on other fields
Hi, I have 3 fields in a form: CATEGORY, NUMBER and YEAR. In addition to inserting these 3 fields into a database table, I would like to insert a... -
Blank fields in database
Hi, I have a blank field in the database for Address. How do I refer to that? For ex: Set hrRS = Server.CreateObject("ADODB.Recordset") ... -
Do Database fields have a numeric equavilant?
Does Access 2000 actually allocate an numerical reference for each field even if I have given the field a name of my own? Thanks in advance TP -
HotSpot and Database fields
Is it possible to have a hotspot call on a database field for popup information? -
The ScareCrow #2
Re: Printing database fields
query_name.columnList will give you a list of the column names
So, of the top of my head
<MYXML>
<cfloop from="1" to="#myQuery.RecordCount#" index="idx">
<cfloop index="listElement" list="#myQuery.columnList">
<OUTPUT #listElement#="#myQuery[listElement]#">
</cfloop>
Ken
The ScareCrow Guest
-
Dinghus #3
Re: Printing database fields
strange happenings.
I had to make a few small changes to get it to work:
<MYXML>
<cfloop from="1" to="#myQuery.RecordCount#" index="idx">
<cfloop index="listElement" list="#myQuery.columnList">
<cfoutput>
<cfset outVar=#myQuery[#listElement#]#>
<OUTPUT #listElement#=>#outvar#</OUTPUT>
</cfoutput>
</cfloop>
</cfloop>
not sure why it needs to have the extra step in there but it works which will
save time and code. :)
Dinghus Guest



Reply With Quote

