Merge Columns (1 Viewer)

M

Mike375

Guest
This apparently being a one-time cleanup, think I'd want to find those records where more than one field (T1 - T4) has data and, since I don't know programatically which field I want to return, manually resolve the discrepancies, e.g.

Note that I was able to do this with absolutely no reference to macros (or VBA for that matter). Shaazam!

Whats wrong with the four SetValues. Make the last actions on the macro open the form for all Is Null on T5 and Select All Records and Delete and all over.

Although the quickest is the copy and paste append, then A to Z and delete

Mike
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 13:21
Joined
Feb 19, 2002
Messages
43,371
Mike, you have preempted yet another post with your off target and dangerous advice. If any poster has an insurance question, feel free to jump right in but please, leave the software development advice to people who know something about the subject and we won't offer any insurance advice.

Although the quickest is the copy and paste append, then A to Z and delete
- you are so clueless that you are actually dangerous.

PS, your macro solutions might actually be welcome in the macro forum.
 
M

Mike375

Guest
Pat Hartman said:
Mike, you have preempted yet another post with your off target and dangerous advice. If any poster has an insurance question, feel free to jump right in but please, leave the software development advice to people who know something about the subject and we won't offer any insurance advice.

- you are so clueless that you are actually dangerous.

PS, your macro solutions might actually be welcome in the macro forum.

What is wrong with the copy and paste append into the a new field that you make the first field. I do it all the time with name lists we buy. What is dangerous about that and what is dnagerous about the Setvalues for the problem of which the poster spoke.

Mike
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 13:21
Joined
Feb 19, 2002
Messages
43,371
paste append adds rows to a table. betheball needs to update the existing rows. The Setvalues solution said it didn't need conditions - it does. You don't want to replace a non-null value with a null. Using macros in this situation technically isn't dangerous since the task is a one-time conversion and the only requirement is to complete it accurately. What is dangerous is that someone might waste their time trying to implement one of your Rube Goldburg (convoluted) solutions.
 
M

Mike375

Guest
paste append adds rows to a table. betheball needs to update the existing rows.

Agree and surely anyone knows that. So it is either applicable or it is not applicable.

The Setvalues solution said it didn't need conditions - it does. You don't want to replace a non-null value with a null.

But that is what he wants. If there is a value for T1 he wants it in a new column called T5. If you don't move T1 across the row because T5 is Null then where do you put it. Only one answer, you need another row and we know tat can't be any good because that is why you knocked copy and paste append. Read his post again and all the records on T5 will be Null to start with.

"In my current table structure, there is a set of four columns named, hpothetically, T1, T2, T3 and T4. For each record only one column has a value. The rest are blank. I've decided that is a bad idea. So I am creating a new column, T5. Is there a way to merge the data from the four existing columns to the new column? "

So why does the macro need conditions. So what is convulted about the solution. Why not criticise Malcys solution which is a waste of time since T2 will rub out the T1 update and etc.

What conditions would you place on the Setvalues...That T5 is not Null. That would be just great!!!! since he made a new column with no entries.

I will bet this is what he has:

T1......T2....T3.....T4.....T5
X
..........Y
Z
.................A
.........................B
C
................D

Etc.

If T5 is to be a "stand alone" with entries not relating to other entries then copy, paste append and delete the the empty records is easily the quickest.

If the values have to be moved sideways to T5 then give me a quicker and better way than the macros.

And again, I would just love to know what conditions you would place on the SetValue. Obviously the only condition is one that stops the SetValue. But that would defeat what he wants to do.

Mike
 
Last edited:

WayneRyan

AWF VIP
Local time
Today, 18:21
Joined
Nov 19, 2002
Messages
7,122
Can't resist:

If each record has ONLY one of the 4 columns, then use an Update Query
for column T5.

Update to: [T1] & [T2] & [T3] & [T4]

Wayne
 
R

Rich

Guest
Mike375 said:
And again, I would just love to know what conditions you would place on the SetValue. Obviously the only condition is one that stops the SetValue. But that would defeat what he wants to do.

Mike
Grrrrrrrrrr
 
M

Mike375

Guest
Pat Hartman said:

Dear Pat,

The only thing that is "hopeless" is your lack of ability to deal with varying conditions. That is why you have so much time to spend on this forum. As a professional developer.......if people were buying your solutions you simply would not have the amount of time for the forum. You appear to be a person who thinks a business should be built around the data base rather than the other way around.

Take a tip from what Rich does. I asked a question about getting numbers from 1 to 1010 onto one page. He solved my problem even though the question was addressed to you. The facts are you would not be able to solve the problem because you would be unable to read that we only want a printout.

Also, I am sure you have seen this before but who knows.... Arguing with me is like wrestling in the mud with a pig. Eventually you realize that the pig enjoys it :D

Get yourself a life and realise that your way is not everyone's way and my way is not everyone's way etc. and....microsoft provided many ways to produce a solution. Often the solution must be produced within an environment that exists.

Mike
 
R

Rich

Guest
I don't want to learn anything, I'm not going to change anything, there's nothing wrong with my db, and in anycase I'm selling this pile of cr.. to an unsuspecting mug in two years anyway...
Grow up, or shut up !
 
Last edited:
M

Mike375

Guest
Rich said:
Grow up, or shut up !

I don't want to learn anything, I'm not going to change anything, there's nothing wrong with my db, and in anycase I'm selling this pile of cr.. to an unsuspecting mug in two years anyway...

Why would you post that as if it is a quote from a post I have made.

Do you normally misrepresent?

It would appear that you are the one who needs to grow up.

Mike
 
R

Rich

Guest
Admirable! you've had a change of heart. Will you finish it within two years? :rolleyes:
 
M

Mike375

Guest
Rich said:
Admirable! you've had a change of heart. Will you finish it within two years? :rolleyes:

As you well know I will put in place anything that is efficient....such as your suggestion with the Report and the numbers of 1 to 1010.

Sometime ago Mile O Phile showed me how to replace a macro SetValue for change RecordSource with code...placed on a label. That was not efficient because with the macro I can change it while the data base is open. Not so the code attached to the label. Have to go to Form/Design to change it.

But you should not misquote. While you and I know you misquoted others will not know. Lying is never a good policy....at least in the long run.

Mike
 
R

Rich

Guest
Mike375 said:
As you well know I will put in place anything that is efficient....such as your suggestion with the Report and the numbers of 1 to 1010.

Sometime ago Mile O Phile showed me how to replace a macro SetValue for change RecordSource with code...placed on a label. That was not efficient because with the macro I can change it while the data base is open. Not so the code attached to the label. Have to go to Form/Design to change it.

But you should not misquote. While you and I know you misquoted others will not know. Lying is never a good policy....at least in the long run.

Mike
I haven't lied about anything, just reminding you of your policy wording that you've quoted here, again and again and AGAIN. Newbies might not be able to read the small print. Oh, and you can replace a label with a text box by the way :rolleyes:
 
M

Mike375

Guest
Rich said:
I haven't lied about anything, just reminding you of your policy wording that you've quoted here, again and again and AGAIN. Newbies might not be able to read the small print. Oh, and you can replace a label with a text box by the way :rolleyes:

If the code to change RecordSource is on a TextBox how would that differ from a label in terms of changing the chosen record source. With a macro we bring the data base window forward. Perhaps if the code was a module?

That was not my policy wording. If you wish to alter policy wording then that should be noted. I am 100% happy for you to rephrase what I said as long as you note you have rephrased.

Your post is a lie because you have put up your rephrase as a quote. Please note what is written above your "quote"

Quote:

Mike
 
M

Mike375

Guest
Rich said:
Yes it is! you've bored us sh..less by continually reiterating it.

No, it is your rephrasing that you put up as a quote. Since you are standing by it then you are a liar. Could you show me where it was posted.

I would also remind you that it was you and others that triggered things. All I did was answer a question about the size of .mdb files. You will also find if you check the other thread that virtually all of my postings were responses. If it bored you shitless then I would hate to see how much space you would take up with something that did not bore you.

But you are a liar with your quote. And what makes it worse is that you have made your writing blook like a quote.

Does this mean the next time I see one of your "quotes" it can't be relied on as a quote.

For someone whose life is obviously very much this forum I am suprised that you would make up someting and then do it as a quote. Do you also have a multi identity on this forum??

Mike
 
M

Mike375

Guest
Rich said:

Doing your icon face does not change the fact that you are a misquoter...that is, a liar.

We now know that none of your quotes can be trusted as they could be reworded as you have clearly demonstrated on this thread.

Mike
 
R

Rich

Guest
Who is we? Just you and your over inflated ego? :rolleyes:
Is it the long dark Aussie winter nights that's making a couple of Antipodeans posting here pugnacious at the minute?
 

Users who are viewing this thread

Top Bottom