473,385 Members | 1,478 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Take two fields and manipulate into one

4
I would like to take two fields and manipulate the information into one.

Example:

SELECT
EMPCURRPOSN.PERM_IND,
EMPCURRPOSN.FT_IND
I would like to combine these two fields like below but cannot fiqure out how to do this. Would a decode work?
IF (EMPCURRPOSN.PERM_IND = '1' and EMPCURRPOSN.FT_IND = '1' then 'FULL TIME')
FROM
EMPCURRPOSN

Any idea's??
Aug 11 '06 #1
3 2388
ronverdonk
4,258 Expert 4TB
Expand|Select|Wrap|Line Numbers
  1. CREATE TEMPORARY TABLE temp (remark CHAR(10));
  2. INSERT temp (remark) VALUES('FULL TIME');
  3. SELECT 
  4. EMPCURRPOSN.PERM_IND, EMPCURRPOSN.FT_IND, remark
  5. FROM EMPCURRPOSN, temp
  6. WHERE EMPCURRPOSN.PERM_IND = '1' 
  7. AND EMPCURRPOSN.FT_IND = '1'
Ronald :cool:
Aug 11 '06 #2
tammy
4
Thank you for the information :) However, when I try this it does not work. We are working with a new program and it does not seem to accept alot of the more complex statements. We seem to have to do work arounds alot. Do you have any other suggestions?
Aug 11 '06 #3
ronverdonk
4,258 Expert 4TB
I am somewhat amazed. What does not work here? These are some very simple (sort of join) MySql statements. What db are you using?

Ronald :cool:
Aug 12 '06 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: Dave | last post by:
I've written a perl program to manipulate data formats so that I can import data from an estimating software program to an accounting program. Works just fine, with the following caveat: The...
3
by: Lars Rune Nøstdal | last post by:
struct X { unsigned int a : 1; unsigned int b : 1; }; int main() { X* x = new X; x->a = 1; x->b = 1;
1
by: Simeon Nevel | last post by:
As a personal exercise, I'm trying to create a call tracking DB for my own use at work. Here's an abbreviated version of the database layout: Company: CompanyID - Primary Key (Text Length...
5
by: Megan | last post by:
Hi everybody- I'm helping a friend with a music database. She has an old one and is creating a new one. She wants to compare records and fields in the old database with records and fields in the...
2
by: Darryl Kerkeslager | last post by:
As the subject above hopefully makes clear, I want to do several reports, "with lots of fields not otherwise in database". These reports also have variable-length text. I have defined the...
3
by: Simon | last post by:
Dear reader, For matching of two fields it is required that the fields has the same content. But now I have the situation that two text fields has not precisely the same content but there...
3
by: shaqattack1992-newsgroups | last post by:
Hello Everyone, At work, employees have been using a spreadsheet that I am trying to import into an access database to make some reports. The problem I'm having is that in the spreadsheet, they...
1
by: bmdlfc | last post by:
Morning all, long time reader, first time poster. I need to manipulate an existing CSV file and create another one from it but excluding some fields. For example, the fields I have in the...
1
by: bimeldip | last post by:
Hi, I have managed to create codes to display data from the database in a html page.I have gone on to create a page to allow users to manipulate the table via a html page. For instance users will be...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.