Tuesday, May 24, 2011

StyleVision Supports XBRL for Financial Reporting Part I – Creating GAAP-Compliant Reports and StyleSheets with a Single Click

Did you know that StyleVision is also an XBRL rendering and reporting tool that will allow you to create GAAP-compliant financial reports with the click of a button ?

image

In this post we'll show you how ...

Tuesday, May 17, 2011

Switch Statement vs. Look-up Table in MapForce

One of the great things about working with software developers is you not only get to create new things that never existed before, you also get to see how other peoples’ minds work when they discover alternate solutions to any design challenge.

We received a comment from a software developer on our recent post titled Expandable If-Else Works like a Switch Statement in MapForce regarding one of the examples we used.

The reader suggests that our second example illustrated a problem that would be more elegantly solved in Altova MapForce with Value-Map than by our Expanded If-Else statement.

Here was the original example that received the month as a string of characters and needed to generate the corresponding number:

Original Expanded If_Else example in MapForce

A Value-Map in MapForce is an alternate solution that functions as a look-up table, whereas an Expanded If-Else acts like a switch statement. Here is how our mapping would look with a Value-Map in place of the Expanded If-Else:

Value-Map alternative in MapForce

Yep, that’s it.

Rather than copying, pasting, and modifying sets of elements the way we built our original Expanded If-Else, a Value-Map lets us easily create the entire look-up table in its Properties dialog:

Value-Map Properties dialog in MapForce

We accept the commenter’s point -- Value-Map definitely works better for the problem we chose because it’s much quicker and easier to create! The table from the Value-Map properties is also more concise and easier to interpret in MapForce-generated mapping documentation than our original Expanded If-Else structure.

Of course you can’t always replace an Expanded If-Else statement with a Value-Map. Data entering the Value-Map must equal a single value in the input table to generate a specific output, whereas Expanded If-Else lets you set up a series of conditions with different logical tests.

Sometimes the exact nature of a data conversion project makes it a judgment call to use a switch element vs. a look-up table.

Let’s say your project receives input as a number that represents a wavelength of the electromagnetic spectrum and you want to handle ultraviolet, visible colors, and infrared energy individually. In that case we could use an Expanded If-Else to test for ranges of input values. The Expanded If-Else section of the mapping might look like this:

Expanded If-Else mapping in Altova MapForce

If the input is an integer, you could also create a solution using Value-Map, but you would need to build a very long look-up table. And then what happens later if the project requirements change and the input becomes a decimal number, or you need to filter each visible color separately by name?

Essentially Altova MapForce is a really cool graphical representation of a complete software language toolbox that insulates you from detailed programming language syntax, with a rich collection of components you can assemble creatively to solve your own data mapping, conversion, and integration challenges.

Find out for yourself how easy it is to apply MapForce to your own data mapping projects. Download a free 30-day trial of MapForce.

Wednesday, May 11, 2011

Visit Altova at Tech*Ed 2011

image

Beginning May 16, you can find the Altova team in Booth #615 at the Georgia World Congress Center in Atlanta, Georgia.

As a Microsoft® Tech*Ed 2011 Silver Sponsor, we will be on the exhibit floor discussing how the Altova MissionKit® tools are helpful for developers, designers, and DBAs working with Microsoft technologies.

Altova MissionKit products include seamless integration with Visual Studio®, powerful functionality for SQL Server® database management and reporting, integration with SharePoint® Server, functionality for working with OOXML, diff/merge for Word documents, and much more.

Stop by to enter for your chance to win a license for MapForce Basic Edition – our graphical data mapping, conversion, and transformation tool – and to chat about what you are currently working on.

We look forward to kicking of our 2011 tradeshow season by talking with you next week!

Monday, May 9, 2011

Diff / Merge for Databases

You may already be familiar with the diff/merge functionality Altova DiffDog brings to working with source code, XML, and Word files – but did you know you can also connect to, compare, and merge database data and structures?

DiffDog supports all major relational databases and includes a Connection Wizard that lets you quickly connect to one or more. As shown in the screenshot below, natively supported databases include Microsoft® Access™, SQL Server®, Oracle®, MySQL®, IBM® DB2®, Sybase®, and PostgreSQL.

Altova DiffDog database connect wizard

When you compare different database types, DiffDog even resolves datatype naming inconsistencies. This means you can compare the customers table in your SQL Server database with a backup copy, for example, or you can compare the contents of any tables or your entire database schema between IBM DB2 9 and Oracle 11g implementations.

Note: Altova DatabaseSpy includes the same diff/merge capabilities described here.

Database Content Differencing

It's easy to compare database content in DiffDog. Simply connect to the database(s) required, and select the tables to be compared. DiffDog displays the compared components side-by-side, and tables and columns are mapped automatically based on configurable options. You can also change or create mapping connections manually when needed.

After you click the Start Comparison button, DiffDog displays results with informative icons. In the simple example below, the content in the database tables is not equal.

Next, you can launch a detailed comparison of the unequal table to see the content of the compared columns side-by-side, with differences highlighted. Tool bar buttons let you merge changes in either direction.

 

Database Schema Differencing

It's just as easy to compare database schemas in DiffDog to, for example, identify and merge differences between a development and production version of the same database. All database items (e.g., data types, constraints, keys, etc.) are displayed in the comparison components so that you are able to compare the structure of the tables within the database schema.

You can merge the two schemas or selected items using Left and Right buttons on the tool bar, or access more merging options via the right-click menu.

DiffDog-DB-schema-diff

Database schema changes aren't merged instantly - DiffDog always creates a SQL change script compatible with your target database type that you can review before committing the changes to the database.

Altova DiffDog database schema compare merge options

You can also save the SQL script to a file or open it for further editing in DatabaseSpy.

 

Learn more about the powerful database diff/merge functionality in DiffDog. You can also download a free trial to give it a test drive.

Tuesday, May 3, 2011

Solution to the Software Testing with State Machines Challenge

Last month in our blog on Software Testing for State Machines with Altova UModel we discovered unexpected behavior in our model of an air conditioning system and challenged readers to improve the design. This post describes one possible solution.

When we ran the Tester application for our model, we saw that the Power switch did not turn the system off when it was in the Standby state. In the state machine diagram in our original model, the only route into Standby from Operating mode is via the Standby button, and the only way out of the Standby state is to press the Standby button again, as seen in the detail below.

Detail of a state machine diagram in Altova UModel

We can create an alternate exit to power off the system from the Standby state simply by drawing a new transition line from Standby to the Off state, and assigning powerButton() as the event that triggers the transition. UModel makes assigning the trigger easy by providing a pop-up window listing events that are already defined in the model.

Pop-up list of triggers for transitions in a state machine diagram in Altova UModel

Our completed revision to the model with the new transition from Standby to Off looks like this:

State machine diagram in Altova UModel

After regenerating the Java code and compiling the new version, we can run the Tester application again. The Debug output message window shows that the system entered Standby in Event 3. Event 4, activation of the Power button, now sets the state to Off.

State machine test application generated by Altova UModel

Find out for yourself how you can enhance the logic of your own state machine diagrams with Altova UModel – download a free 30-day trial today!