+ All Categories
Home > Documents > Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM...

Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM...

Date post: 02-Jan-2016
Category:
Upload: reynold-bruce
View: 233 times
Download: 2 times
Share this document with a friend
Popular Tags:
20
Advanced Lawson SQL The Secrets of SQL Genius
Transcript
Page 1: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Advanced Lawson SQL

The Secrets of SQL Genius

Page 2: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Your Database Flavor

• Oracle• Microsoft SQL Server• IBM DB2• Other?

Page 3: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

What is covered• Overview of Databases• Introduction to SQL• Introduction to Select statements• Examples (Grouping, Sorting …)• Tools and getting started

Page 4: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

All the Lawson DBs• Application Productline (Prod)• Logan• Gen• FS• RS• SC• SN• MSCM• TF80 • Cubes• DataWarehouse …

Page 5: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

The Problem• Lawson Has Several Databases• Each database has several hundred tables• The Table names do not necessarily make sense• The constraints (relationships and indexes) are

not applied to the database itself which makes it hard to reverse engineer them

• There is no easy to reference documentation telling you where to get the data

Page 6: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Making it a bit easier• There are several tools that can make the

perocess of retrieving data out of Lawson much easier. o dbdef – The database definition utility

• Index definition• Relationship Definition

o dbdoc – Database documentationo dburf – Program documentationo Lawson Portal debug mode – Alt+ctrl+Ao Portal Field Help – Shift + Ctrl + Oo rngdbdump – Range Database Dump o count utility – Database Counts by Productlineo Management Studio

Page 7: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

dbdef• Great way to explore the tables and discover their

relationships

Page 8: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

dbdef

Page 9: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

dbdef

Page 10: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Value list

Page 11: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

dbdoc

Page 12: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Portal Tricks• Debug Mode: Alt+Ctrl+A

Page 13: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Portal Tricks• Field Help: Shift+Ctrl+O

Page 14: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

rngdbdump

• rngdbdump -c live employee -f FIRST-NAME LAST-NAME PROCESS-LEVEL -v EMP-STATUS=AG

• Output:"Florance","Edwards","20""Julius","Jamison","20""Alexia","Vali","20" 3 Records

Page 15: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Count utility

• Count prod

Page 16: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

What You Need• A SQL Client (SQL Server Management Studio,

Toad, WinSQL )• Connection information

o Server Address (IP Address or Server Name)o Port Number o Username and Password

• User credentials (User needs at least “Select” rights)

Page 17: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

So why sql?Here are some examples of what using SQL can enable you to do:

• Adhoc reporting• Database clean up

o Finding duplicates in tableso Finding orphaned records

• Hacking GENo Reports and Jobso Users

• Fixing and understanding bookmark issues• Manipulating LBI data • Updating tables with missing information (not

recommended unless you know exactly what you’re doing)

Page 18: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Examples

Page 19: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Next Event

Jun 18www.nogalis.com/education

10x Upgrade BootcampThe one day event that will ensure a successful upgrade

Page 20: Advanced Lawson SQL The Secrets of SQL Genius. Your Database Flavor Oracle Microsoft SQL Server IBM DB2 Other?

Q/A@nogalisinc 


Recommended