Author: way0utwest

  • Grinding Away: Iris Classon

    Iris Classon is a developer and Microsoft MVP. She has had a lot of success across the last decade plus. This is her second career, deciding in 2011 to leave her profession as a registered clinical dietician to learn to program. Here’s an excerpt of an interview:

    “Well, the first few days sucked. I mean—yes, you might want to beep that out. Because our teachers are doing, counting, talking about binaries, and I had forgotten all the math. They’re talking about binary numbers and doing all the calculations. They’re talking about hardware as well, which I didn’t know anything about. I know now, but not then.

    I was so frustrated. On the second day, I was like, “I want to go home.” I was kind of upset and stuff, so my teacher drove me home and we had a long chat, and he said, “Iris, come back. We kind of need a personality like that. You just come back. Give it the rest of the week and you’ll see.”

    On the third day, when I came back—I did come back—we started programming. We did our first little console application, and I just realized I just got it. I would turn around and look at my classmates. Some of them just seemed confused and I was like, “What is the problem? I mean, this is logic.”

    For the first time in my life, I understood what was written.”

    Her first year of programming is documented on her site, and it’s a neat read to me. The important thing is to remember she documented this daily during that year. It’s summarized now, but she was grinding away.

    What I like about this

    This is a story I think shows practically how to improve yourself and get better at something new. I have remembered this story as I tried to learn to coach over the last ten years, and as I continue to work on trying to improve my skills.

    This is also in tech, and it gives you a way to look at yourself and try to improve your skills to find a better position, or maybe the position you really want.

    What I don’t like about this

    Not everyone can take time off to improve for a year, though this is something most of you could do across 3-4 years.

    I also don’t want to make it seem like anyone can do this. Everyone has certain genetic gifts, and they are drawn to certain things. Iris clearly is drawn to very logical work and has a gift for programming. Your experience, raw talent, and understanding might not be as good.

    You can get better, but you walk your path and you have to remember that. Reading other stories can sometimes feel like I can’t do that. You won’t likely do the same thing, but you can improve yourself a lot of you grind away.

  • Republish: Over-Engineering

    It’s Black Friday, and a holiday in the US. I’m off today, no idea what we’re doing, but probably some horse chores and taking it easy.

    You get over-engineering as a republish. I realized it was never on this site, so here it is:

    Over-Engineering

    This editorial was originally published on Jul 15, 2009. It is being re-run as Steve is on holiday.

    I stumbled upon an old blog post by Neil Davidson that he recycled via Twitter. It was about design and how things bloat. In the post he references another blog by Moishe Lettvin , who worked on the Shutdown menu in Vista. Reading that post, I was amazed to find that 8 people directly and 43 people indirectly contributed to that feature over a year.

    Really?

    At first I had the amazing response that most people probably have of MS is obviously so (insert your four letter adjective here) blanked-up, no wonder Vista was late. However as I read through the comments, I saw so much disagreement over how the feature works, should work, compares with OS X, and more that I’m not sure so this was a year of development time wasted. (Note I don’t know the man-years spent on this, but I bet it’s > 1).

    I haven’t built a lot of software in my career, especially large scale or shrink wrap software, and so perhaps I don’t really understand things. However I do think that we tend to over-engineer too often. I see people that try to design in every contingency, as well as think of every possible places things might go wrong. I have a simple mantra for you folks:

    You can’t do it. Get over it and ship something.

    It sounds simple, but it’s not. But it’s not necessarily naïve. I’ve seen too many people delay releasing something, trying desperately to get things right. They’re never right. They’re also never done, so you might as well ship something that’s 80% right and then plan on fixing it right away.

    I know some people will disagree and say that things should be built right the first time. I don’t think they ever are. They can be built well, but they ought to be built quickly, and with a design that expects changes to be required in  a relatively short time frame after they’re released. This doesn’t work for all software, but I bet it works for a large class of applications that aren’t on the scale of SAP or Windows.

    We can learn to code better, build more secure and stable software, but I don’t think we’ll ever cover all the bases. So why try? Build something that works most of the time and then refine it from there.

  • A New Word: Nachlophobia

    nachlophobia – n. the fear that your deepest connections with people are ultimately pretty shallow, that although your relationships feel congenial in the moment, an audit of your life would reveal a smattering of low-interest holdings and uninvested windfall profits, which will indicate you were never really at risk of joy, sacrifice, or loss.

    I don’t have nachlophobia. Maybe in my younger years, but I deeply value connections with those I choose to spend time with. I have learned to make an effort at events to spend significant time with a few people, even if this means I don’t get time with others.

    I have no fear that I’m not risking anything; I am. I am truly saddened when my close friends experience pain and joyful for their success.

    A few weeks ago at the PASS Summit, I spent an hour sitting in a mostly empty room with a friend, talking about life. We chat periodically, but we don’t see each other enough. It was worth every minute. I also had to go offsite to an event and another friend asked to ride with me. I was grateful for the company and conversation, something I don’t get enough of.

    I hope none of you have nachlophobia. If you do, spend time building strong relationships, which are defined by you. It doesn’t matter how others feel about me, it’s about how I feel about them.

    From the Dictionary of Obscure Sorrows

  • Adding Test data to msdb.sysjobhistory

    One of our internal people was looking to test some process in (I assume) Redgate Monitor and needed more job history than they had in msdb.sysjobhistory. They wanted to use SQL Data Generator to help, but couldn’t make it work.

    This gives the solution I sketched for them. It can work with some other system tables, but not all. Many system tables do not allow user data to be inserted. Some do.

    The Main Problem

    The main problem here is that SQL Data Generator doesn’t see system tables. If I open a project in msdb, I see this:

    2024-11_0297

    That matches what I see in SSMS. Only user tables.

    2024-11_0296

    However, I know I can do this and it works.

    INSERT INTO dbo.sysjobhistory
      (job_id, step_id, step_name, sql_message_id, sql_severity, message, run_status, run_date, run_time, run_duration, operator_id_emailed, operator_id_netsent, operator_id_paged, retries_attempted, server)
    VALUES
      ('EA6B3BC3-D358-4B0C-A793-8C3C558098AB', 0, 'mystep', 0, 0, 'Executed as user: NT Service\SQLAgent$SQL2022. The job script encountered the following errors.'
      , 0, 20241111, 175438, 0, 0, 0, 0, 0, 'ARISTOTLE\SQL2022')

    Now, how to get SQL Data Generator to help?

    A Little System Table ETL

    Since I know I can insert data into the table, how can I generate data? Apparently SQL Data Generator cannot read these tables, but I can use a trick that I’ve used in the past.

    First, I’ll run this in msdb:

    SELECT *
      INTO mysysjobhistory
      FROM dbo.sysjobhistory AS s
      WHERE 1 = 0

    This code will make a copy of dbo.sysjobhistory with no data. However, this is a user table. Once I do this, now I can refresh SQL Data Generator and I can see my table.

    2024-11_0094

    Now I can use the settings to get the type of data I want. Here’s a preview of some data I set, using the data in my existing table.

    2024-11_0095

    Now, I can click generate data and I have data added to my user table. If I query this table, I see data:

    2024-11_0096

    The last step is to move this data. I’ll use this query:

    INSERT dbo.sysjobhistory
       (job_id, step_id, step_name, sql_message_id, sql_severity, message, run_status, run_date, run_time, run_duration, operator_id_emailed, operator_id_netsent, operator_id_paged, retries_attempted, server)
    SELECT job_id, step_id, step_name, sql_message_id, sql_severity, message, run_status, run_date, run_time, run_duration, operator_id_emailed, operator_id_netsent, operator_id_paged, retries_attempted, server
      FROM dbo.mysysjobhistory AS m

    Once this runs, I can see the data in msdb.

    2024-11_0097

    Of course, I’d also have to populate sysjobs if I wanted this linked to a job and shown in the Agent Job History Viewer.

    Summary

    This post showed how I’ve sometimes worked in situations where I couldn’t directly access a table from an application. In this case, I want to get data into sysjobhistory, but SQL Data Generator doesn’t support that directly. My solution:

    1. make a copy of the table
    2. insert data into the copy
    3. move the data into the original

    This has worked in a few situations as well where I might need to move/stage data before it gets into an application table. In this case, we wanted to generate some random history for Redgate Monitor to read.

    This can work for other tables as well, as long as you can insert..select into them.

    SQL Data Generator is a neat tool to generate data quickly for a variety of purposes in SQL Server. Give it a try, especially if you already have the Toolbelt Essentials.