Idiot Proofing your Software

Today I just want to talk about something that is pretty obvious to most people, but I hope to give you a few new ideas on it anyway.  The topic today is idiot proofing your application.  Now, let me go on record by saying idiot proofing your software is pretty much impossible, however, you still need to you best.  I had a friend that used to tell me, “you can monkey proof your software all you want, but they just hiring better monkeys”.

So do you just run through it once, and call it good since you know it’ll be broken anyway?  of course not.  For me, this has always been a challenge.  I’m part of a small business, and I’m the lone developer.  That means, I’ve gotten really good at fixing the things I know will happen, but it also means that I tend to get tunnel vision.  I believe it a common thing among developers, but the key is to avoid that trap.  So here are some of the ways I’m trying to improve my own products…

1.  Get someone that knows nothing about product to play with it.  If I could get her interested, my wife would be a perfect test subject.  She doesn’t use SAP, she knows nothing about service, but she does understand IT and software.  By getting someone with no idea what is supposed to happen means that they will push all the buttons you never expected anyone to push.  They will also look at it from a purely aesthetic perspective, something that I don’t do as well.

2.  Next, if you can, get someone that isn’t good with software, but understands the business.  this will give you the true test if you got the right info.  If someone looks at the information generated, and says “this would help me run my business”, then you’re onto something.

3.  finally, get another developer to look at your stuff.  they’ll look at some of the ways you’ve done things and ask “why?”  Often, we know a way to do something, so we don’t look for better ways.  Often I’ll go to someplace like tech-ed or even a blog post and notice a strange piece of code.  I look at it closer, next thing you know, I’ve found a better way to do something 🙂  The problem is that I don’t have the time to reveiw everything, and I’m biased, so I don’t see anything wrong with my approach.  But…  if someone else asks why did I do this, instead of that? well, it forces me to look at my stuff and either explain why it had to be done this way, or I may say…  hmmmm, that’s a better way.  Now I know a new way to do it.  ha ha ha

The last point is to do this early and often in your development cycle.  Point #2 is really something you should get before you even start programming.  Sketch what you’re thinking, and show it to a business person.  Ask if it would help… if not, why bother?

Anyway, this has been on my mind lately, so if you have some other good ideas, or are interested in playing with anything I’ve done, I’m always interested in having another set of eyes look at my stuff.

thanks,

Mike

Variant Configuration – Using a Parameter ID in a Dependency

Another fun tidbit I learned from my friends at Elogic.  Have you ever needed the model to change based on who is running it???  I know it sounds unusual, but I ran into this scenario.  We had a group that was constantly updating the bill of materials, however the business had begun a round of testing.  They needed to have the BOM locked down, but we didn’t want to have the modeler’s doing weird things just to test the new things they created.  For this, we used a Parameter ID in a dependency to handle this issue.

So, we created a copy of the BOM that was consistent.  This would provide the business with a bill of materials that wasn’t constantly adding new materials that would change the MRP results, or costing amounts, or introduce new errors.  Then, in our test environment, we added both BOM’s and used a parameter ID to determine who would see each bill of material.

Now for the new part, using a PFUNCTION, we called an ABAP function that would check for a specified user parameter.

* Read the user setting for this parameter
CALL FUNCTION ‘G_GET_USER_PARAMETER’
EXPORTING
parameter_id    = l_parid
IMPORTING
parameter_value = l_parva
rc              = l_rc.

l_parid is the paremeter ID to look for, and l_parva is the value returned from that parameter.  Using this function, you can define the cstics you want to use.  then you can assign this PFUNCTION exactly like any selection condition.

While I admit, it won’t be common, you never can tell when this could come in handy.  If you need more code around the PFUNCTION, just ask, but it’s pretty easy stuff.

Happy configuring…
As always, if there is anything we can help you with, please press the contact us button above, and let us know what we can do for you.

Mike

Getting Some Help – When is it the right time?

Being a small company, it’s a big deal whenever you start thinking about bringing in more help.  Right now, I’m the only developer for a small software company.  that means, I have a limitless amount of work that I can do, and since I’m still doing consulting, my time isn’t limitless 🙂  So, how do you fix this issue…

1.  Space the work out, and prioritize!!!
2.  Bring in some additional help

Recently, my partner found someone interested in working with us…  but are we ready for it?  Since I am admittedly a bit of a control freak when it comes the software, I’m naturally resistant to the idea.  Do we need it?  can we afford it? How do I know he’s any good? etc.

So this post is going to be about all the things to consider when you start to think about bringing in some help.

1.  Financial:  We’re small, so we can’t afford to pay someone by the hour, especially for something that “may” sell, but we don’t have any orders for it.  that pretty much leaves paying a percentage of sales on the product.  Even this is hard because our margins are still tight.  We’re offering big money for anyone that can get us a lead (FYI.  $10,000 is still out there if you connect us with a lead that brings in a sales.  No selling, just give us the lead).  On the flip side, 100% of 0, is still 0.  So it’s better to get a some of something, than get nothing…  you get the idea.  Plus, it may help open new markets/prospects.

2.  The application:  It must be designed as a standalone application, but still be easy to integrate with our existing offerings.  Sounds easy, but since I’ve done all the development, I haven’t really documented my standards.  So having someone new comes in would force me to figure out what I want.  While I am the CTO of this venture, I haven’t really acted like one up till now.  I’d still need to review the code, but this would give me a chance to learn some new techniques.  Never a bad thing. finally, is there a market for the new product?  Is it really important enough to bring in someone new?

3.  Legal:  This is the tough part.  We need Non disclosure agreements, as well as documents that give our company complete ownership of this stuff, and still provide the % to the developer.  We need to expressly state that no money changes hands until we get paid.  Plus, there is the whole issue of developer license.  We only have one currently, but I’ll talk more about that in section 4.

4.  Technical:  How will he develop?  I’d have to set up a system for him to create everything in and provide access to that system.  Not impossible, but certainly one more challenge to deal with.  The developer license is an issue.  We only have one, so do we need to buy another, or can we find an alternative?

Anyway, these are the angles to consider.  I think I’ve made my choice… but I’ll talk more about that in the future =)

thanks for reading,

Mike

Making a Sales is a Lot Like Dating

I heard this statement in one my marketing lessons, and it really struck me as an interesting analogy.  When I stopped to think about it, it really is more true than I imagined.  So let’s look at this, you’re looking to make a sale, what’s the first thing you need, you need a customer.  The customer is key to everything, without them, you have nothing.  I know what you’re thinking, duh!!!  But bear with me as I get to my point 🙂

A customer is a lot like looking for husband/wife.  You may go to a bar, or meet someone in a public place.  Do you see someone, and just walk up to a stranger and ask them to marry you???  Of course not.  But why?  because you don’t know if they are a fit for you, or vice versa.  Plus, what person in their right mind would say yes.  So how do you figure out if you’re “right” for each other.  You take small steps.  How about going out for coffee to talk?  Well, in the business world this is a lot like checking out your website or blog.  It gives your prospect the chance to get to know you slowly.  By putting out a blog, you let the prospect see that you know what you’re talking about and figure out if there’s any reason to go further.  So, you’ve gone for “coffee” and kinda like what you see.  So you move to the next level, how about a real date…  in the business world, this would be some form of opt-in, like an auto-responder, a mailing list, or a newsletter.  This says I’m interested enough to get free info from you…  but nothing more.  Ok…  now you’re dating…  but it’s still early stages.  It doesn’t mean you’re exclusive or invested…  just interested.  Now if you have enough qualities your customer likes, they may buy something small from you… a sort of trial thing.  This could be like meeting hte parents, or going on vacation together.  It’s still not marriage, but it’s pretty serious.  If the customer likes the small thing they bought, they may finally invest in your big offering…

Now of course marriage isn’t a perfect analogy, since you want as many customers as possible (well, unless you live in Utah).  But you get the idea.  You need to present enough value to get the customer interested in you.  They aren’t just gonna give you their money until they know you can provide the value you claim.  Plus, if you follow the idea of the “Ideal Customer”, you want to check out the customer too and see if they fit for you.  This is a two way street (of course, in my case, I’m early on, so my ideal customer is anyone that will buy from me.  ha ha ha).  but I look forward to becoming more exclusive in the coming year.

anyway, thanks for reading,

Mike

ABAP – Screen Elements Naming Convention

It’s been a while since I put a post out about code, and since I’ve been spending a lot of time creating screens lately, I thought I’d drop a quick tidbit out there for any of you programmers out there.  Lately, I’ve been creating screens to work as a configuration screen for one of our applications.  What this means is that there are lots of screen elements, radial buttons, etc in order to make it look good.  I have a table behind the scenes to hold all the information, but like normal screen design, you don’t make a table that goes 1 to 1 with the screen, it’s too inefficient.

Why do you care about any of this? Well, by following a standard naming convention, you can make life really easy on yourself.  Let me give you an example.  I have a screen with about 100 radial buttons (30 rows, some with 2 options, some with 3, some with 4).  Well, by following a naming convention with a standard prefix, putting the field name in the same spot, and adding the occasional suffix, you can dynamically read the field name and make it work for everything you put on the screen without having to read every line.

In your PBO, you can do something like this:
LOOP AT SCREEN.
CLEAR: FIELD, VIS, I, Z_CONFIG_WA.
if screen-input = 0.
continue.
endif.
CASE SCREEN-NAME+0(3).
WHEN ‘CH_’.
FIELD = SCREEN-NAME+3(4).
READ TABLE Z_CONFIG INTO Z_CONFIG_WA WITH KEY FIELD = FIELD GRPNAM = GRP.
IF SY-SUBRC <> 0.
READ TABLE Z_CONFIG INTO Z_CONFIG_WA WITH KEY FIELD = FIELD.
ENDIF.
IF Z_CONFIG_WA-FIELD IS NOT INITIAL.
ASSIGN (SCREEN-NAME) TO <FIELD>.
CASE Z_CONFIG_WA-VISIBLE.
WHEN ‘3’.
<FIELD> = ‘X’.
WHEN ‘4’.
<FIELD> = ”.
ENDCASE.
ENDIF.

ENDCASE.
ENDLOOP.

Now, some of the key things to notice, one is that the loop continues if you can’t input anything.  this is purely to speed things up.  Next, by using the position, you can check for the prefix.  In this example, it’s CH_

Next, it finds the key field name to plug into the configuration table.  Next up, it checks to make sure that the table entry exists in the custom configuration table.  As long as it finds an entry, we use a field symbol to assign the value to the screen field.

The awesome part of this is that as long as you maintain a consistent naming scheme, you can set the values for multiple screens and reuse the code.

anyway, I hope this is useful for you.

If there’s anything we can do to help you out, please use the Contact Us Button above and let us know what we can do for you .

Thanks for reading,

Mike

Big Development Projects – Don’t Get Discouraged

I’ve been working on the latest piece of software for JaveLLin Solutions, and recently hit that frustrated/burned out point on it.  This piece is called Proximity, and the basics have already been designed for the transactions.  However, we are doing a major overhaul, adding some additional functionality and adding a configuration screen to give the user flexibility.  Now, I’ve been working on the redesign for the past few weeks.  Yesterday, I thought I had it wrapped up except for minor tweaks.  I handed it off to my partner (he’s done the specifications for this one), and he came back with a rather extensive list of things to add/update.  While is great, we are getting a better product, more robust solution, and just an overall system that should be easy to sell…  so how could this possibly be a problem???

The problem comes in purely from the amount of time I’ve spent, and of course, the disappoint of not being complete with something I thought was finally completed.  So, how do you avoid this letdown?  Let’s start with a few simple things you can do to get refreshed…

1.  Take some time away from this project.  While normally I recommend single tasking everything, sometimes when you’ve been working on the same initiative for weeks, you need to recharge the batteries.  Take me for example.  After I got the news, I almost picked up the keyboard again and angrily started hacking out the updates.  While this could work, my head isn’t in the game.  This would lead to not doing my best work.  So I’m taking the day off and doing some marketing stuff.  In fact, that’s why I’m blogging right now 🙂

2.  Try not to get too invested in your work.  For me, this is nearly impossible, but I’m trying really hard.  After spending weeks doing some great work and fun new enhancements, so suddenly get broadsided with a big new list of things to work on, can hit you personally.  Go back to number point 1…  and then review the changes.  Remember that this isn’t personal, it’s all about making the best product possible.

3.  Review the changes and determine what needs to happen right now, compared to what can wait.  Often things are nice to have, compared to required.  it’s important as a small shop to properly prioritize what needs to happen.  This means looking at what is currently being used by a customer (something you’ve already sold), what has “legitimate” leads for purchase (actual customer interest in the product, have looked at the product so far and decided they will purchase given some additional cleanup/functionality), then what is just something you “believe” customers will want.  Now I am very guilty of doing everything in that third bucket.  While this belief that customers will want it is important to brainstorm new ideas, the important thing is what customers REALLY want.  Of course, this becomes more challenging if you don’t have any actual customers yet.  Regardless, prioritize…  development time is a vital resource, be sure to use it wisely…

4.  Finally, find a way to re-energize yourself about the project.  Get excited about you’ve done, and how these little tweaks will make it even better.  Convince yourself, in any way that it takes, that this is the best use of your time =)

5.  Make the changes, and finish the project =)

I’m certainly open to additional methods you have any.  I’d love to hear from you.

Mike

Variant Configuration – Exploding Variant Configuration BOM Completely

Recently, I learned a new trick from my friends at Elogic, and I since I didn’t want to forget it, the easiest way is to share it with all of you 🙂  I had a request from the business to know every components, exploded all the way down to the lowest level, so they knew what materials would need to be created in the new test system.  Initially, I couldn’t think of a good way aside from looking at the planned/production orders.  Then Lawrence showed me this trick for exploding variant configuration BOM completely…

  1. Ensure that your configuration profile does not explode only configurable assemblies.
  2. Go to  transaction CAVC_TEST transaction and click on the CAVC_O_ORDER_BOM_INIT button.  Fill in the sales order and item.  Click Execute.
  3. Click on the highlighted button below, then click the Execute button.
  4. Click on the highlighted button below:
  5. Press Shift-F8 when the List screen (below) appears.
  6. Save the Component list wherever you want.

 

Well, hope you find this useful.  this is brand new transaction to me, so I’ll have to continue playing with it.

In the meantime, if you need more in depth help, press the contact us button above and let us know what we can do to help you.

thanks for reading,

Mike

 

Variant Configuration Performance Tuning

This lesson is timely because I’m dealing with this issue right now at my current client.  Their model uses class nodes in the bill of material VERY heavily, so we’ve been noticing awful performance in CU50.  SAP does provide some solutions for variant configuration performance, take a look at the following note to get some additional ideas:

Note 917987 – General performance in variant configuration

Now, we have done a few things in an attempt to improve the performance.  First, we were using class type 200 with a reference characteristic.  I learned, for class nodes this is actually a no no, unless you check a box in configuration to redundantly store the characteristic value.  Here’s what SAP’s help says about it:

Class Maintenance

Using Reference Characteristics Only

This constellation cannot access the database directly to read the assignment records. All classified objects are processed sequentially.

In order to change it, you must check that little box up top for redundant storage.  Now the drawback of this approach is twice as many table entries.  For that reason, we chose to move the characteristic to be NOT a reference cstic.  The only issue this causes is that value for material number (in our case) will not be populated automatically.  Not a huge deal.

Now, we changed all of that stuff, and still no change.  this was disappointing.  After some debugging, we (using transaction SE30 for performance tuning) we found that the issue was with table KSSK.  Surprise, Surprise, it holds the class connections.  So we handed it off to basis.  They began by running statistics on all of the tables listed in the above OSS note.  Still no help…  finally, we needed basis to reorganize the tables and indexes for KSSK & INOB.  This may sound like a lot of mumbo jumbo, but if you ask your basis person it will make sense to them =)

Short story is that sometimes you can get performance without changing your model.  Now I don’t regret the changes we did, they will still be beneficial, but don’t forget about the technical aspects.

As always, if you need further help in variant configuration, please press the contact us button above and let us know how we can help,

thanks for reading,

Mike

Variant Configuration – Delete Class Assignment

After yesterday’s post, I thought I’d throw this one in there too.  In your Development environment you may find that you need to delete class assignment of a class or another material inside of CL24N or CU42.  It could be you need a smaller class, or just accidentally linked a material that shouldn’t have been connected.  Why isn’t the issue.  You got yourself in a pickle, it’s dev, so you’re willing to live with the potential inconsistencies in order to get your model right.  After all, like we discussed yesterday, you absolutely, positively do NOT do this in production.  Then you use ECM or make a new material and replace it like any other engineering type change.  Ok… now that I have that out of the way, let’s get to the good stuff =)  You can use SE38 to put the breakpoint here straightway (it’s by far the fastest way).

Program: LCLFMF2D

Form: LOESCHEN

          if sysubrc is initial.
call function l_check_function
exporting
cucp_var_class_type       
allksskklart
cucp_root_object_key      
allksskobjek
cucp_root_object_table    
sobtab
cucp_datuv                
rmclfdatuv1
cucp_aennr                
rmclfaennr1
exceptions
deletion_allowed          
1
deletion_allowed_with_ecm 
2
others                    3.
case sysubrc.

 

Set sy-subrc = 1

Then execute the remainder of the code (F8).  That’s all there is to it 🙂

it’s scary that it could be that easy to delete class assignment, even though SAP transactions won’t let you do it =).

If you ever need more help in VC or SM, please use the contact us button above and let us know what we can do to help.

thanks for reading,

Mike

Variant Configuration – Deleting Class with Assignments

Just recently run into a fun little challenge, and my newest VC mentor pointed me in the right direction.  (Thanks Lawrence =) ).  In the dev system, you will often create models, do some testing, and then realize you did the wrong thing (sometimes a simple change, sometimes an epic failure.  ha ha ha).  If you reach the epic failure and need to perform deleting class that is assigned to some orders or materials, you can override the system.  This the little tidbit can help you get rid of stuff in your model that should no longer be there.

DISCLAIMER.  Do not do this in production.  This is an ugly way to make this happen, so it should only be done in development.  It will likely leave sales order line items/production orders in an inconsistent state.  So please use this technique as a last resort.

Go to transaction CL6M (delete class with assignment).

enter in the data you want to delete, but before pressing execute, go to the transaction box and enter /H then hit enter.  This will drop you into debug.  As an alternative, you can place these breakpoints using SE38.

Program: RMCLKDEL
Form: CLASS_ALLOCATION

find the line:
IF NOT VERWKZ IS INITIAL.

You will need to change the variable: verwkz =to initial.

NEXT:

Find the following code in the listed form:

Form: VERWENDUNG_KLASSE_KONF

* Verwendung in Konfiguration
CALL FUNCTION ‘CUCP_CONFIGURATIONS_EXIST’                 “051516
EXPORTING  CUCP_VAR_CLASS_TYPE   = KLART     “051516
CUCP_CLASS            = KLAH-CLASS”051516
CUCP_DATE             = DATUV     “051516
EXCEPTIONS USED_IN_CONFIGURATION = 1.        “051516
IF SY-SUBRC GT 0.                                         “051516

You will need to change the variable sy-subrc to 0 or initial

* ÄNDERUNG AUF DIREKZUGRIFF AUF ANWEISUNG DURCH DIE STÜCKLISTEN  3.1H
* Grund: tote Positionen
CALL FUNCTION ‘CLEX_BOM_CHECK_USAGE_CLASS_DIR’
EXPORTING
CLASS_NAME = KLAH-CLASS
CLASS_TYPE = KLART
EXCEPTIONS
NOT_USED   = 1
OTHERS     = 2.

*… Fehlernachricht ausgeben, falls Klasse verwendet wird.
CHECK SY-SUBRC NE 1.

Finally, change the variable sy-subrc = 1.

now you can execute (F8) the remainder of the program and your class will be deleted.  If you have open sales orders you wish to continue using/testing with, you should go in change mode and visit the configuration.  You may show an inconsistency depending on the class and it’s location in the structure.  Be sure to delete any inconsistencies and validate the cstics and values you still need in the configuration.

Once again, if you need any VC help, please use the contact form above and let us know how we can help,

Thanks for reading,

Mike

Posts navigation

1 2 3 85 86 87 88 89 90 91 97 98 99
Scroll to top