Find A Field
Queries, stored procedures and udf's have been developed over months or years and now you need to see where a field is used. This SQL query provides the means to see every occurrence of this field in the database. The result shown is the name of the query, stored procedure or table where this field is found. This SQL script can also locate occurrences of fields in Boyum tables.
What Table Gets Updated?
Some queries get complex. SAP Business One does not provide a complete database schema (that I know of). This query shows the table record counts. I use it to see what gets updated when I click the 'Add' or 'Update' button on a form. The result shown is a list of the number of records in each table. Comparing the before and after 'update' tells you which tables had records added.
Import XML Data into SQL tables
This routine shows how to import data from XML into a SQL table.
Export Data from SAP to a Flat File (CSV)
This routine shows how to export data from an SAP file to a CSV file.
Find the Latest Date a Price was Changed
Within SAP there is detailed tracking of the 'change log' for an item. If you wanted to get the last date a price for a specific item was changed, the information is in the change log. However, what if you want to use this information in a query? Or look it up more quickly than comparing item log instances one at a time within the change log? This database 'function' provides the means to use an item - price list number to get the last price change date.