473,654 Members | 3,308 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Field to textfield

Is there a way to take an entire row from a table and convert it to an
output string? I want to use the string and append it to a text file.

Thanks Wes

Apr 20 '06 #1
3 1279
we****@ispace.c o.za wrote:
Is there a way to take an entire row from a table and convert it to an
output string? I want to use the string and append it to a text file.


You can use CONCAT() function to combine values from different columns.
The result will be a single string:

http://dev.mysql.com/doc/refman/5.0/...functions.html
Apr 20 '06 #2
While the concat function is great, if you ever want to move this to a
real database engine like oracle... you can/should the ANSI standard
syntax.

select field1||','||fi eld2||','||fiel d3.... from tablex where ....

Apr 20 '06 #3
on*******@first dbasource.com wrote:
While the concat function is great, if you ever want to move this to a
real database engine like oracle... you can/should the ANSI standard
syntax.

select field1||','||fi eld2||','||fiel d3.... from tablex where ....


It should be mentioned that one has to set the SQL_MODE of
PIPES_AS_CONCAT or ANSI to enable this syntax.

Using this syntax without either of those SQL_MODE values in effect is
still a legal expression. The double-pipe works like logical OR when
not running in ANSI mode. So the resulting value of the expression will
be 1, which might be confusing.

Regards,
Bill K.
Apr 20 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
22742
by: MT | last post by:
Hi all, this sounds like an easy enough thing to do, but after spending 45 minutes searching google and various javascript sites I can't find out how to make a textfield (textbox or whatever you want to call it) in an html form be a mandatory field. I'm guessing it would be on the "submit" click, and a pop-up would appear saying to enter data in teh field. Can anyone recommend a good javascript site? thanks in advance.
0
1310
by: kews | last post by:
Hi, I need to automate a textfield for various inputs. It needs to automaticlly retrieve the text from the textfield. The length of the string in the textfield varies...What is the best solution - to put a timer and fire an event on the textfield ? regards, Kewin
1
8004
by: Mark Noten | last post by:
This following HTML page works fine in Firefox 1.5 but not in IE6. Help is appreciated. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"> <meta http-equiv="content-script-type" content="text/javascript"> <title>Just a test</title>
1
4776
by: Tony | last post by:
Hi, I have an ID text field that is composed of two alphabetical letters and the rest are numbers. This field is also a primary key. In this same table, I want to separate this field into two fields. Then make these two new fields primary keys. The first just contains the two alphabetical letters. The second contains the numerical digits. Is there a way to do this without losing current data? Thanks,
7
2598
by: Nez | last post by:
Help needed! Hello, I have looked everywhere for a solution to my problem and this is pretty much my last resource. I have created a table in a span with the innerhtml command in my code behind. In this table I have created textbox html input fields. Now I need to allow the user to change the value in the textfield, and compare it to the old value I have stored in a cookie. Problem is, because the textfield was created in the code...
4
2434
by: bpneary1 | last post by:
First of all, I want to thank everyone who posts messages in this group. I am very new to VB and developing full-blown database apps, and I have learned a great deal by reading these posts, so I am very grateful. I have a problem that I have been working on, and I was wondering if anyone had a simple solution. I have a table of data similar to the example shown below:
3
4816
by: cbradio | last post by:
Hi, I am having trouble developing a form in a restricted environment. My sample code is found below my message (sorry I don't have a URL). Basically, without a doctype, the form displays properly with 3px padding around each form field, and no overlap. But the doctype changes the box model, I am told, and so the padding is added to the 100% width, leading to overlap and poor presentation. Unfortunately, I'm forced to use the doctype due to...
16
1951
by: shyamg | last post by:
Hi, this is my javascript validating the fields in mozilla FF but its working and validating only one field. how to write the and how to works the script .................. function Test(){
8
8707
by: sneddo | last post by:
Ok I am trying to do the above, I have got a script that will restrict the length but it requires the user to enter the field and hit a key, before it will work. This would normaly be find, but the title field gets its information from a previouse page so its value can easily be over 40 chars. (I can not restrict the length on the previouse page.) The major dificulty is that there is no form on the aspx page, and I do not have access to...
0
8379
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8294
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8816
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
7309
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4150
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4297
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2719
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1924
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1597
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.