Friday, December 27, 2013

How to present PowerPoint slides over the internet via PowerPoint Broadcast Service

There is a nice feature in PowerPoint that you can use to present PowerPoint presentations without the need for GoTo meeting, Lync, etc. The The presentation is embedded within a web browser so you don't need local software like GoTo meeting installed. A great quick way to share your decks for sales demos or training.

I don't see too many people leverage the PowerPoint Broadcast Service option, but its truly a great feature when all you want to do is show a PowerPoint with low overhead. This is just a little tutorial in case you didn't know about this.

I'm trying something new and placing all steps in a single image. Not sure if I like it or not yet but wanted to try something new. Kinda thought it might be artsy and fun but may come off cluttered and messy. Might be the last one I try like this.

Thursday, December 12, 2013

Debug code in 'runTableMethodIL' in AX 2012

On occasion in the debugging process, you will not be able to access some code you can see written in Dynamics AX but for some reason is not hitting your breakpoint.

Other than a few things to look for like a breakpoint on a field method or debugging enabled on server, its possible the code of interest is actually running in the CIL (Common Iterop Lanuage) via the runTableMethodIL x++ call. Unfortunately, due to the way the debugger app works, you can't plow into the code after this method. There are ways to do it but sometimes I need to jump in quick so I change a line of code or change as user option to have it call the AX method normally instead of via the CIL optimized way so I can debug like normal.

There are two ways to handle this:
Option A: Change the 'Execute business operations in CIL user option' to false (should by default be set to true)
Option B: Temporarily change the code for debugging.

For option B, the code change method is pretty easy. Just comment out the CIL line and replace it with the static call to the tables static method detailed in the runTableMethodIL method. See the picture below for an example.This comes in handy when debugging not just using your user (e.g. processes running under users other than your current user).

THIS IS NOT A PERMANENT FIX. This is just so I can debug this situation quickly and is a very helpful quick tool. I would highly recommend switching it back before promoting your code aka as soon as you're done tinkering.

The reason for the CIL is that the application gains performance by running in CIL.

Figure 1 - The 'Execute business operations in CIL' option

Figure 2 - An example of the code switch

Sunday, December 1, 2013

Questions from college students and my answers to them

This post doesn't have anything to do with ERPs, retail, or coding but I felt it was important to write about since these are my personal thoughts and experiences and that is what is important to me more than other topics.

During interviews, it is vitally important for those being hired to interview the company they are interviewing for just as hard as the company is interviewing them. Finding a candidate to be a good fit is a two way street and I always like to stress this. The best consultants are the ones who are honest and love their job.

That being said, I recently did some interviews for college students and was asked a few questions that I found to be pretty consistently asked. I thought I would write my thoughts on them here in this post.

There were two questions asked by almost everyone. They both are very supplementary and kinda have the same answer I think.

  1. What does a day in the life look like for a consultant? Varies greatly.
  2. What are the biggest challenges day to day while being a consultant? See question 1 above.

The answer is that some weeks I have my headphones on and typing away 80% of the time while others, I don't even put them on even though I had planned to. I might think I'll be in the office on Monday but then something popped up last minute and I'm Texas less than 48 hours later teaching a class on X++ development. While those situations can be some of the most challenging due to timeline, it's where I've found the most success in personal/professional growth and that addictive adrenaline rush... I don't think I can find in other jobs.

Here are a few other responses questions with how I answered. Hopefully people looking into consulting will get some use out of these.

What would you change about your company?  

There are always things that can be changed with any company. Some have way more things than others. As companies evolve and grow, the things I would like to change often change from year to year as issues are addressed. The number one thing I would look at in assessing a company from an outside position is their ability to adapt to change and have the drive and leadership to go to that level. For example, larger companies can have issues that just linger there for a long time with little ability to change due to the infrastructure and culture in place. 

That being said, company size is a big thing (for me personally) to look at when assessing if a company is right for you. This is a big personal preference question. I removed the pros/cons of each type as there are so many I don't want to get into it. I'm a small business guy. Grew up in them and just feel comfortable there as there is more freedom for initiative and creativity. I like to say yes to things and tasks but I've found out that I like that mentality to be reciprocated.  Different strokes for different folks.
How often are consultants on the bench?  

This is a tricky one to answer. The nature of consulting is very cyclical with everyone being on the bench from time to time. It all depends on what accounts are doing what and what we can use resources for on them. For example, if someone can code in addition to functional finance, they will naturally be more busy even in times when they are working more than 40 hrs a week. This is also true for senior consultants.

The best way I can answer this is to say that you should never truly be on the bench as there is always something to learn and work on in the technology world. Ask around to everyone and anyone including internal projects to get experience. As a consultant, there are so many places to grow and you should be able to keep yourself as busy as you want. I know I personally have a laundry list of things for people to work on that span the gamut of skill sets including blogging.

In your experience, what makes someone a successful employee coming right out of school? 

 In my experience, right out of the gate, the top three are all values, not skills: hard work, great attitude, and being open to saying ‘Yes’ at every opportunity you feel you can accomplish with the best of your ability. The biggest thing in making someone stand out is being willing to do whatever it takes to succeed (ethically that is). Unfortunately, it’s hard to teach those values in a classroom as it boils down to character and the individuals ambition for a certain level of success. Investing time up front when starting your career will pay dividends as it will afford you more opportunities down the line.

Are there any certifications that you recommend to consultants?

To be honest, certifications are good on paper and that’s about it outside of book smarts. They are a great baseline but the information may not be as valuable until actual experience is gained first. As a rule of thumb, I think all functional consultants should be a little technical and all technical consultants should definitely be smart functionally. Here is an interesting blog post that shares my feelings on the topic:

Saturday, November 16, 2013

Natural Language Processing (NLP) in the self-service Business Intelligence (BI) world

I wrote a blog post back in February of 2011 about 'ad hoc' reporting vs 'self-service' reporting: DAXDude: AX 2009 Ad Hoc vs Self-Service reporting. The point of the article was to say that the two terms were synonymous. I recently had someone make a comment on that post bringing up the point of 'Natural Language' reporting being the future of reporting. Instead of responding to that comment directly, I decided it might be best to write a post on my thoughts on the concepts. I did quite a bit with it back in my pre-ERP programming days.

What is 'Natural Language' reporting?  
Natural language reporting rests in the Natural Language Processing (NLP) computer science field and has to do with how end users (people) interact with computers in a way that mimics how they would interact with other people. Basically, the end user will state a question or command to the computer or robot and the computer will translate that request in its own language to determine an action whether that is something physical like moving or retrieving data. It is a major component to the artificial intelligence sciences.

This technology has been around a long time and was a concept people widely became familiar with in the 90's with the introduction of More recently, it is used in Apple's personal assitant dubbed 'Siri' on the iPhone. NLP reporting is basically allowing the user to type/ask a question into a field (like a search engine) and have the system return back data that is relevant to the question asked.

As an example, someone may ask the system: 'How many sales orders have I written?'. The system would then translate this into its language by recognizing key words like 'How many' indicating that the user wants to know something and 'Can you' asking for an action. From there the system would have to be able to recognize that the user wants a query to be run for 'sales orders' and 'I' being the current user. This could all boil down to the system returning the results of [select count(recId) from salesTable where salesTable.SalesResponsible == 'daxdude'].

Using the example above, one might be able to start seeing where the complexity comes in for making this type of solution robust and reliable for reporting. For example, be a system tester and try to think of how many ways you can break this thing. Broken english, slang, missing qualitiers/identifiers, etc are all easy starting points. These things need to be pretty complex and have an advanced workflow to guide the users to the data they need.

Self Service Business Intelligence (BI)
Self-service BI is an important aspect in the modern, dynamic business model. It's all about getting the right information to the right people at the right time. Often, the requirements to accomplish that change frequently. This is especially true as companies become more dynamic in their growth plans. An end user can either define their needs and submit the requirements to someone on the IT team to develop (which could take some time) or be enabled to retrieve that information through a set of tools that enable the user get access to that information on their own. The later of the two options is self service BI whereas the first option is more traditional and common in older systems. Having such self service capabilities can help increase efficiency and allow identification of issues before they become a problem.

The core requirement of a self-service BI solution is to give the end user easy to use tools to quickly and efficiently get the information they need. I usually look at the below criteria in evaluating a reporting solution.
  1. An easy to use and understand graphical user interface (GUI)
  2. Dynamic enough to allow complex, fast data retrieval for users comfortable with the tools
  3. Have as much reporting work completed by the end user as possible.
  4. Data is real time or as up to date as possible
  5. How and where can the reports (and report creation tool) be used 
  6. Translation of retrieved data into relevant visual representations
  7. Extraction of reporting from BI solution into external systems/files
Benefits to NLP reporting
There are a few benefits to NLP reporting. There are not many listed below, they are unique strengths that other reporting methods may not have. 

Benefit 1: A user doesn't need to know tables/fields in the database for the data to be retrieved. They can say 'What are my year to date sales for Wisconsin?' and the system 'should' be able to show the user the the year to date sales for that person for that state.

Benefit 2: Data retrieval can be done through voice (hands free) Think about the application being on the shop floor or a warehouse. I know several companies currently leverage voice picking. Imagine allowing the users to query information about their performance in relation to their target while on the floor. Or even in the board room where the fewer the clicks to get new data, the better for all involved.

Benefit 3: Retrieval of ad hoc query data can be fast. Often in the time it takes to just type or say a single sentence.

Benefit 4: People not comfortable with computers might like this reporting best. This can be older people or younger kids. I have worked with people that use computers almost exclusively for getting certain information and that is it. Think of the application in a place like a museum. People could download an app for that museum that is leveraging NLP and allow people to ask very specific questions about certain exhibits. NLP would make the experience intuitive and bridge the technology gap to allow everyone of all ages to get their questions asked.

Issues with NLP reporting
There are many downsides to utilizing an NLP solution for robust ad hoc reporting capabilities. I see very specific places where it can be helpful, but depending on the cost and maintenance, it might be a very tough sell to justify in a very good majority of situations. My personal opinion is that it is should be used as more of a supplemental BI solution for specific situations and not as a complete corporate solution for BI.

Issue 1: Data is often one dimensional in an NLP structure. Creating multiple complex joins to retrieve data in ways the system might not be able to automatically link is near impossible.

You definitely cannot create things like end user OLAP cubes (think 3-dimensional spreadsheet data views) by simply asking a question. There are so many factors there that can create issues even if the technology existed for that right now. And then imagine coding for the constantly changing database schemas in all the new ERPs. And the customizations customers may make to their system which would need to be taken into consideration in any BI solution.

Issue 2: It can be incredibly frustrating for end users to get the information they need if it is something very specific and it is not being translated between the human and computer languages correctly.

For example, lets look at Apple's Siri personal assistant. How many jokes have you heard about people asking it something and not getting back an appropriate response? It's very hard to get the users to phrase the questions correctly so that the internal associations in the NLP engine link to the correct pieces of information. When the technology is used by well trained people (think in the commercials or in a sales demo), it will work 100% of the time. When it is not, the success rate can be much lower. Ask yourself: Do you want people to be making jokes about your implemented BI solution because they asked the wrong information or it wasn't possible to render?

UPDATE (12/16): Here's a Simpson clip making fun of an Siri (NLP) and their shortcomings.

Issue 3: Data reliability and confidence is usually higher in solutions where the end user spends a little more time to research what fields/data need to be used in the query to retrieve the data. It provides more visibility into behind the scenes and eliminates the black box.

If the data is complex and the engine is somehow able to handle it, what would your estimated level of confidence in the data be if you didn't personally connect the dots? It might be right but when the boss asks 'How can you tell these numbers are accurate?', what will you say?

Issue 4: Multi-lingual support. What if the solution is in English and the end user doesn't know that language?

Issue 5: Dialects. If someone has a thick dialect (say someone from Chicago) attempting to query the data, they may not be able to be recognized by the voice engine. This is becoming less of an issue as technology continues to improve and data engines with APIs that do this translating are becoming more advanced.

Note: With a good engine and proper training, some of the issues above can be reduced but they will still be there to some degree.

Issues with ad hoc reporting in general
Often times there are issues with all types of ad hoc reporting. I'll only address one in this post but I believe it to be the biggest caveat and downside to ad hoc reporting: Incorrectly retrieving information.

Data in systems, especially in normalized structures, can be quite complex and may not be easily translatable to an end user. When users attempt to configure the pieces to report against the data, there is a chance they will miss something or incorrectly interpret what it is they are seeing. This can propagate incorrect information  

As an example, there once was a client that came screaming into the room (literally) asking for an explanation as to why the numbers they were seeing in their warehouses for on hand inventory were off by a significant amount. They were so upset they needed an explanation right that minute as what they were seeing was inexcusable. The natural answer was that the person couldn't tell them because they didn't know how the numbers in the report were retrieved. To cut right to the chase, someone queried the data wrong and the numbers were WAY off. Once correctly queried, the numbers were about where they expected due to the nature of their business. That was all a billable activity to correct. It created a lot of frustrations for all parties involved. All was good in the end though!

Note: There are ways to mitigate the bad data situations but those are far from being fool proof.

Natural Language BI as the next step in BI evolution?
The comment in my old post asked "Don't you think that Natural Language Business Intelligence is the next step of Business Intelligence's evolution?" 

This is a fair question to ask but I want to distinguish between artificial intelligence Jarvis App Demo and natural language BI. For corporate business intelligence, I don't really see it evolving to the point of adding too much value for a very long time. The technology has existed far longer than modern self service BI solutions.

I really only see this technology being a supplementary tool for BI reporting but is not 'the future' per se due to the issues I stated above. For it to truly be the future, the technology would have to have the artificial intelligence level of an advanced end user who knows (and evolves with) the company's unique business processes (and recognizes different modifications) and the ERP database system being used. And do that reliably and provide a reasonable degree of confidence in the returned data.

By the time the above is achievable, I'd be more afraid of my coffee machine being upset at me and half-assing my coffee. Remember that Back to the Future - Pt 2 portrayed multiple home fax machines as the wave of the future:

As for Qwalytics, their solution might be perfect for some applications and I will keep them in the back of my mind in being a possible solution if the right application were to arise.

Here is their website:
Here is a demo of the solution:

I'd be interested in how their solution has been used to add value to companies. I couldn't find any case studies on their website but that does not mean that they don't exist.

The preferred self-service BI solution I prefer for the Dynamics AX ERP
As far as robust self-service BI for corporations go, I really like the Halo BI platform. I'd highly suggest you to check it out. While some issues still exist that are inherent with self service (as detailed above), the Halo team has started to explore ways to solve some of those issues like assessing the quality of the report's data.

While I don't want to plug too much or anything, I did want to throw my preference for BI solutions in this post since I plugged someone else.

Not every solution is right for everyone in all situations but maybe this one is for you. Request a demo if you want to learn more:

Tuesday, November 5, 2013

Dynamics AX 2012 - Reset/Clear your user's usage data

Within Microsoft Dynamics AX (2012 and earlier), you may encounter issues where someone within your organization asks you to clear your 'usage data'. It will likely be because you are experiencing issues in your AX application that isn't happening for everyone else and maybe after an AX code promotion or deployment. It's usually one of the first things people check when debugging an issue for an end user or system tester.

CAUTION: By clearing your usage data, you will loose any previously stored queries and personalized forms used via Intellimorph. If its a specific area of functionality you need to fix, you might be able to clear the specific usage data creating the problem without loosing everything.

It's not too crazy of a process but can be intimidating if you are new to the system and don't know where to go and what it does. I will explain 1) how to clear your user data, 2) what usage data is exactly, and 3) why you may need to clear it

How to clear your usage data:
  1. In your Dynamics AX instance, you will want to navigate to ‘File’->Tools->’Options’ (Figure 1 below)
  2. Click on ‘Usage Data’ in the ‘Options’ form that opens up (Figure 2)
  3. Click on the ‘Reset’ button in the ‘Usage Data’ form that opens up (Figure 3)
  4. Click ‘Yes’. (Figure 4)  NOTE: This will only reset the usage data for your user, not anyone else’s
To make sure everyone is clear, the above will remove all your personalizations under your user including boxes that you previously checked as 'Do not ask me again'.

What is usage data?
Usage data is essentially AX's way of storing what you did last in order to provide a way for end users of the system to personalize and optimize their experience with the ERP.  Usage data is unique for every person.

For example, if you go into an AX form and move a field on a grid one field to the left, every time you go into that form in the future, AX will show you that field moved to the left. This way, every user in AX can have AX remember what they last did to that object whether it is values in a query/report, form layouts, templates, etc.

Technical dive example:
When a form is opened, AX will look at the universal object for the form. From there, it will see if the user opening the form has done any personalization to the form (aka a usage data record for that object seen in Figure 5 below). If the record doesn't exist, the form will open like it looks in base. If the record does exist, the data in the usage data record for that object is considered. The data in the record is a container that basically tells the system what data the user entered last or what needs to be where (like fields) that varies from what the base AX object in the AOT.

Why do I need to clear it?
On occasion, like in the case of new development to the underlying objects in the AOT, AX will not be able to translate the data in the usage data container for an object being used. This can result in an error upfront or a non-critical error that just creates extreme slowness or 'weirdness' as it can be reported.

Hitting the 'Reset' button in Figure 3 below will just tell AX to wipe the slate clean on things. It's a safe, fast bet to resolve whatever might be ailing you in AX that might only be happening to only you and not your fellow cohorts in your business unit.

UPDATE 11/21/2014 - Read the comments below for information in regards to selectively deleting records from usage data as well as how usage data templates are stored and removed. I added a picture in Figure 6 to supplement the comments as well.

Is there still something not working? The field you just added to the form still not showing up for certain user(s) even though it is for others? Here are some things to check:

  1. Make sure they are in the correct environment 
  2. Try an apples to apples sanity check:
    1. Log into AX from a working user. 
    2. Make sure the field(s) in question are there. 
    3. Share your screen with the user having issues. 
    4. Right click on the Dynamics AX icon in the start menu in the way to run AX as a different user (in Windows Server 2012, go to the Start screen, richt click the Dynamics AX 2012 application tile and select that option)
    5. have the user then enter their credentials by giving them control of your screen
    6. Verify the issue exists/is fixed and go from there
  3. Go to the users machine and make sure that they don't have the form up anywhere when the usage data is reset. This includes if it is in a ListPage embedded in AX. Get another list page loaded if you have to, then reset the usage data
    1. The reason for this is that the usage data is recorded in AX when the form is navigated away from. If its still up, the usage data is cleared, then the user navigates away and back to it (to refresh the form), the old usage data will be saved again when the page is closed and then reloaded with the old data unintentionally.

Figure 1 - The 'Options' location for your Dynamics AX user

 Figure 2 - The 'Usage data' button under user options

Figure 3 - The 'Reset' button under usage data form

 Figure 4 - Click on 'Yes'

Figure 5 - A close look at the data within usage data

 Figure 6 - Usage data record rendered on form vs the template record (see comments below)

Sunday, October 27, 2013

AX for Retail: AX code changes not being reflected in POS operations

Issue: When making customizations to the AX for Retail POS class in AX 2102 [Classes\RetailTransactionService] (also known as the AX RTS class), the changes are not being reflected in the operations coming from the POS.

Example of issue: The AX RTS class is modified show additional information in the POS which is time sensitive data and must be retrieved from the headquarters at the time of inquiry (when RTS should be used). The changes are made but the POS is operating like the old code was, not the new code.

Solution: The Retail Transaction Services service (or Commerce Data Exchange in 2012 R2+), which the POS is using to talk to AX, must be restarted for the new code to be seen in the POS. The POS will only use the code as it existed in this class the last time the service was restarted.

Reason: Not entirely sure why this is the case but it appears the code is cached somewhere for the POS instances to use. It doesn't use the code in AX as it changes. I can speculate on why it was designed that way (e.g. performance) but other than that, I'm not 100% sure why it operates that way.

It is pretty common to have the AX developer say an issue is fixed (when in this code) and then have the POS tester see no changes to the code if the RTS service is not restarted. It can create some friction or headaches if you don't know why that is the case. Odds are the AX dev is testing from within AX using a job at which point the RTS component is not utilized so you will get inconsistent results. Once you get into the groove of things, its just one of those things you need to remember to do.

Hope the above helps!

Monday, October 21, 2013

Free shipping promotions - One of the most effective promotional tools

The whole purpose of promotions is to ultimately do one thing: spur sales. Promotions can range from super simple to extremely complex with offering free item(s), dollars/percentages off, etc. Whether the promotion is supposed to sell a certain type(s) of item(s), raise the amount of the average order, or spur sales at a specific time, each type of promotion can help to achieve whatever end goal retailers are attempting achieve.

To note, there is one type of promotion that can be adapted to almost any promotion strategy whether it is on its own or supplementary to another sale: Free Shipping. It does not just have to apply to online sales as some big ticket retailers will also offer this promotion for customers purchasing within their physical stores.

It's one of my favorite promotions, and according to research I found online, it is for a majority of the population as well. While I normally don't trust 'studies' from online and other companies without more intimate knowledge, I believe this one because it resonates with my shopping habits and sales trends I have witnessed in my professional career. Everyone loves free shipping.

Here is a stat from I found online that helps provide additional validation:
"According to 64% of the respondents, free shipping—with or without minimum spend—is the most effective promotion an e-commerce merchant can offer to drive sales during the holiday season.  Coming in second place was another shipping-related promotion. 26% of the respondents chose discounted shipping as an effective tool to drive sales.  Note:  survey respondents were allowed to choose multiple answers."

Below are four personal instances of when free shipping has worked for me in different promotion types:
  • Free shipping for reaching a sales total dollar (or percentage) amount
    • I have spent $100 on stuff instead of only $50 just because I can get free shipping. 
  • Buy a certain item, get free shipping
    • I was buying something online last week and also ended up buying an additional item I liked but didn't really need because buying the item gave me free shipping. 
  • Free shipping for members of a service
    • When I'm looking to purchase items, I also look on Amazon and attempt to get free shipping on 'Prime items' because I pay for a yearly membership to the Amazon Prime service. Plus its two day shipping!
  • Free shipping during a certain time
    • On 'Black Monday' sales, a lot of online retailers will offer free shipping without any strings attached. I don't have to leave my home to take advantage of Black Friday like sales.
So why is it that its so effective? At a philosophical level, people seem to shop based on the saving money, whether it is actually saving money or merely the illusion of doing so. Technically you are saving money by buying $50 worth of product and $10 of shipping ($60 total) instead of purchasing $100+ worth of product and $0 of shipping. Then again, if you buy everything you need to buy in one sales order, you may not have to pay for that $10 shipping charge for two orders (which is technically saving you 20% on items that aren't on sale). Then again, would you actually purchase the items on that second order if you didn't talk yourself into taking advantage of the free shipping?

When you ask someone what are some of the cons of ordering online (or a large item that can't be carried out of the store by the customer), one of the main points will probably be paying for shipping. When you eliminate shipping as one of the cons, it makes the purchasing experience seem so much more attractive as it allows you to to buy the products from a group of companies at low, competitive prices that can be lower than some of the prices you find in a physical store. Plus it saves you time from going out and searching for the items of interest in stores which may or may not have the items in stock and maybe at a higher cost. Additionally, when purchasing from within a store with free shipping, it lets you realize how much time and effort you are saving by not lugging a large item around on your own. Team lifts are really bad single lifts...

Hope that the above provides some additional insight into the awesome 'free shipping' promotion.

Friday, October 11, 2013

What is database normalization? Good/bad? Yes...

There are a lot of people who talk about how important database normalization is for primary functionality tables and make it a talking point when evaluating the technical sides of an ERP. That is all well and good but I think the actual question should be around the developers of the solution and if they took normalization into account with the solution. If a table or set of functionality is normalized, it doesn't really tell me anything either good or bad. It only throws a red flag and a bunch of questions before determining anything else.

Hopefully this will show up on the first page of Bing/Google when someone types in something to the tune of 'AX 2012 database normalization'. <- 'Gratuitous line for search engines'

What is database normalization?

Database normalization (n) definition - (WIKIPEDIA) - Database normalization is the process of organizing the fields and tables of a relational database to minimize redundancy and dependency. Normalization usually involves dividing large tables into smaller (and less redundant) tables and defining relationships between them. The objective is to isolate data so that additions, deletions, and modifications of a field can be made in just one table and then propagated through the rest of the database using the defined relationships. 

Sounds awesome right? Can be, not always. There are pros and cons to it. Sometimes a denormalization structure is best. I don't think anyone will agree that normalization is the answer 100%. While there are more points to the below, I'll only cover a few basic ones.

  • Updating tables can be faster (fewer fields)
  • Can be less risk of database locking
  • More flexibility to expand functionality of solution
  • Removes or reduces redundancy
  • Increase data retrieval times for single tasks (if designed correctly)
  • Enforce relationships between data in joined tables (referential integrity)
  • Can split up a table with many fields that will be quite large into multiple database servers
  • Indexing strategies not as effective as data is spread out across multiple tables
  • If a developer doesn't know what they are doing (or requirements are incorrectly identified), it can create a mess very quickly
  • don't have to worry about joins in a denormalized structure. 
  • reporting and integration can be an easier task than white boarding out a network of tables.
  • Indexing can be more effective
  • Easier to maintain and understand schema
  • Good approach to consider when CPU is an issue
  • Updating tables might be slower
  • Updating development on one large table with many fields
  • Retrieving records may be slower
Basically, the big take away is that this conversation is very situational. Different scenarios make situations unique.  It's like asking a financial adviser how much the person is supposed to sock away for retirement by age XX. Having 50k saved and 10k in credit card debt is worse than 40k saved and 0k in credit card debt. Many pieces in the equation to consider.

The ultimate answer is to know both normalized and denormalized DB strategies. Through thorough planning of a solution, you can determine the best approach. As for asking about database normalization, I think the best initial questions to ask up front are:
    a) are the developers of the solution competent
    b) did they take normalization into account when designing the solution

For more information, I strongly encourage you to do some more research into these concepts. It can only help!

Friday, October 4, 2013

AX 2012 for Retail R2 - error 'The order could not be saved at this time' is being thrown but POS was previously working.

In AX 2012 for Retail R2, you can occasionally see the error 'The order could not be saved at this time' (Figure 1 below).  

Not very descriptive I know. This usually occurs when attempting to save an order (sales or quotes) in the system via a Retail Transaction Services (RTS) call. In case you are unaware, the RTS class in AX is the collection of methods used in the POS to get 'real time' information that is not stored within the POS. 

In addition to the error below, I was also noticing other 'weird' occurrences like lists in a POS form not returning data to the user and forms just not showing up. Very odd and definitely gave off the vibe that something was wrong.

Usually, the error is caused in the functionality of one of two things:
  • issue with the AX Commerce Data Exchange: Real-time Service (CDE:RTS) or Retail Transaction Service (RTS) in non-R2 versions
  • the code in AX attempting to create/update the order. 
As long as the AX and POS code is working correctly and it just started happening, a start or restart of that service might be able to take care of things. I'm not entirely sure of why this occurs and what is fixed by it (but I have a lot of ideas) but it does seem to fix things.

I was seeing this error occur even after the service was restarted and all of the functionality was working previous to this error popping up.  The next step I took was verifying that the call was even making it to AX. Sure enough, it was not but it used to...

Solution: This was actually an issue with the servers memory being totally consumed. The RAM was at 97%. It was a single tier box for AX 2012, the DB, the POS, and acting as a single-tier Sharepoint 2013 topology. Quite a bit going on. And in an earlier release of the VM, there was a rogue IIS Worker Process that was consuming all the memory so I had to keep killing it. 

Needless to say, as soon as I killed that rogue IIS Worker Process, the memory went back down to 82% and everything was working as normal. To clarify though, this memory issue would exist on the server where the CDE:RTS for that store operates.
Figure 1 - The error 'The order could not be saved at this time'

Monday, September 23, 2013

AX 2012 R2 POS Operations full list as of publish date

In AX 2012 for Retail POS, you have the flexibility to add/change functionality behind buttons that the users can access from the UI. I find the need to reference these all the time for various tasks but haven't seen anyone actually post something out there for reference. I'm putting this up more for me to use but hopefully you will find use too!

Below is a full list of retail operations that get shipped with AX for Retail out of the box. It also lists which operations have user access checks for security purposes.


Operation ID Operation name Permission ID Permission ID2 Check user access User operation Action lookup
100 Product sale 0 0 Yes Yes Retail product
101 Price check 0 0 Yes Yes None
102 Void product 1002 0 Yes Yes None
103 Product comment 0 0 Yes Yes None
104 Price override 0 0 No Yes None
105 Set quantity 0 0 Yes Yes None
106 Clear quantity 0 0 Yes Yes None
108 Product search 0 0 Yes Yes None
109 Return product 1017 0 Yes Yes None
110 Weigh product 0 0 No No None
112 Linked products add 0 0 No No None
113 Set dimensions 0 0 No No None
114 Return transaction 0 0 Yes Yes None
115 Show journal 1002 1002 Yes Yes None
117 Add loyalty card 0 0 Yes Yes None
121 Clear salesperson 0 0 Yes Yes None
122 Invoice comment 0 0 No Yes None
123 Change unit of measure 0 0 Yes Yes None
127 Override transaction tax 1018 0 Yes Yes None
128 Override transaction tax from list 1018 0 Yes Yes None
129 Override line product tax 1018 0 Yes Yes None
130 Override line product tax from list 1018 0 Yes Yes None
131 Packing slip 0 0 Yes Yes None
132 Deposit override 0 0 Yes Yes None
200 Pay cash 0 0 Yes Yes Payment method
201 Pay card 0 0 Yes Yes None
202 Pay customer account 0 0 Yes Yes Payment method
203 Pay currency 0 0 Yes Yes Payment method
204 Pay check 0 0 Yes Yes Payment method
206 Pay cash quick 0 0 Yes Yes Payment method
207 Pay loyalty 0 0 Yes No None
208 Pay corporate card 0 0 Yes Yes Payment method
210 Change back 0 0 Yes No None
211 Void payment 1002 0 Yes Yes None
212 Get fleet card information 0 0 No No None
213 Pay credit memo 0 0 Yes Yes Payment method
214 Pay gift card 0 0 Yes Yes Payment method
300 Line discount amount 0 0 Yes Yes None
301 Line discount percent 0 0 Yes Yes None
302 Total discount amount 0 0 Yes Yes None
303 Total discount percent 0 0 Yes Yes None
400 Popup menu 0 0 Yes Yes Menu
401 Sub menu 0 0 Yes Yes Menu
500 Void transaction 1001 0 Yes Yes None
501 Transaction comment 0 0 Yes Yes None
502 Salesperson 0 0 Yes No None
503 Suspend transaction 1011 0 Yes Yes None
504 Recall transaction 0 0 Yes Yes None
505 Recall unfinished transaction 0 0 No No None
506 Card swipe 0 0 No No None
508 Pharmacy prescription cancel 0 0 Yes Yes None
510 Pharmacy prescriptions 0 0 Yes Yes None
511 Issue credit memo 0 0 Yes Yes None
512 Issue gift card 0 0 Yes Yes None
513 Display total 0 0 Yes Yes None
515 Recall order 1022 0 Yes Yes None
516 Sales invoice 0 0 Yes Yes None
517 Income accounts 0 0 Yes Yes None
518 Expense accounts 0 0 Yes Yes None
519 Add to gift card 0 0 Yes Yes None
520 Gift card balance 0 0 Yes Yes None
600 Customer 0 0 Yes Yes None
602 Customer search 0 0 Yes Yes None
603 Customer clear 0 0 Yes Yes None
609 Customer transactions 0 0 Yes Yes None
610 Customer transactions report 0 0 No Yes None
611 Customer balance report 0 0 Yes No None
612 Customer add 0 0 Yes Yes None
614 Edit customer order 1021 0 Yes Yes None
620 Create customer order 1020 0 Yes Yes None
622 Search 0 0 Yes Yes None
623 Edit customer 0 0 Yes Yes None
700 Log on 0 0 No No None
701 Log off 0 0 No Yes None
702 Change user 0 0 Yes No None
703 Lock register 0 0 Yes Yes None
704 Log off force 0 0 No No None
800 Negative adjustment 1002 0 Yes No None
801 Inventory lookup 0 0 Yes Yes None
802 Stock count 0 0 Yes Yes None
803 Picking and receiving 0 0 Yes Yes None
900 Application exit 1002 0 Yes No None
906 Print tax free 0 0 Yes No None
907 Print previous slip 0 0 Yes No None
908 Print previous invoice 0 0 Yes No None
909 Upload printer logo 0 0 Yes No None
910 Restart computer 1002 0 Yes No None
911 Shut down computer 1002 0 Yes No None
912 Design mode enable 0 0 Yes Yes None
913 Design mode disable 0 0 Yes Yes None
914 Minimize pos window 0 0 Yes Yes None
915 Blank operation 0 0 Yes Yes None
916 Windows workflow foundation 0 0 Yes Yes None
917 Database connection status 0 0 Yes Yes None
918 Show blind closed shifts 1023 0 Yes Yes None
919 Extended log on 1002 0 Yes Yes None
920 Time clock 0 0 Yes Yes None
921 View time clock entries 0 0 Yes Yes None
922 View product details 0 0 Yes Yes None
1000 Open drawer 1012 0 Yes Yes None
1052 Tender declaration 1004 0 Yes Yes None
1053 Blind close shift 1023 0 Yes Yes None
1054 Suspend shift 0 0 Yes Yes None
1055 Close shift 0 0 Yes Yes None
1056 Print X 1003 0 Yes Yes None
1057 Reprint Z 1005 0 Yes Yes None
1100 Customer account deposit 0 0 Yes Yes None
1200 Declare start amount 0 0 Yes Yes None
1201 Float entry 1007 0 Yes Yes None
1210 Tender removal 0 0 Yes Yes None
1211 Safe drop 0 0 Yes Yes None
1212 Bank drop 0 0 Yes Yes None
1213 Search shipping address 0 0 Yes Yes None
1214 Add shipping address 0 0 Yes Yes None