Monday, April 21, 2008

Advantage News and Tech Tips

The monthly Advantage Newsletter will be sent out today. The newsletter includes Product News, Press coverage, Events, Tech Tip and new KB Items. It is an excellent way to get a snapshot on what is happening in the Advantage world. You can subscribe to the Advantage Newsletter here.

Starting this month and continuing on for the next several months the Tech Tips will focus on the new features included in Advantage 9.0. This months tip is about support for the SQL MERGE statement. MERGE is often referred to as an "upsert" because it allows for an INSERT and UPDATE statement to be combined into a single statement. Essentially it runs an update statement for records that match specified criteria and an INSERT statement on records that do not match the criteria. The syntax looks like this:

MERGE INTO table1 USING table2 ON condition WHEN MATCHED THEN UPDATE SET column1 = value1[, column2 = value2 ...] WHEN NOT MATCHED THEN INSERT column1 [, column2 ...] VALUES (value1 [, value2 ...])

You can read the April Tech Tip here and you can see a full list of tech tips on the Advantage DevZone. You can get more information about the MERGE statement in the Advantage Help File.

No comments: