Tables and Sets

The AlphaSportsWeb application contains the following tables and sets.

Table/Set

Description

component_breakdown

The component_breakdown table contains notes about which A5W pages contain which components, and notable features to be found in each.

customer

The customer table contains all information that describes a customer. The difference from the version in the AlphaSports database is the new password field.

dummy

The Dummy table provides a single record with a single field with a fixed value. This record provides a common parent or link for other unrelated tables. You can see the use of the dummy table in the TGRDL_HIST tabbed gridlinker component.

invoice (set)

The invoice set contains the information that describes an order. It is the same set found in the AlphaSports database. The set makes the invoice_header table parent to the customer and invoice_items tables. The invoice_items table is parent to the product table, which is parent to the vendor table.

invoice_header

The invoice_header table contains part of the information that describes an order. The difference from the version in the AlphaSports database is the new type field, which defines the source of the sale.

invoice_invert (set)

The invoice_invert set makes the invoice_items table parent to the invoice_header table. The ASWSALESHIST.A5W page uses the set to build sales summary tables.

invoice_items

The invoice_items tables contains the information that describes the components of an order. It is the same table found in the AlphaSports database.

lk_avail

AlphaSportsWeb uses the lk_avail table to list when the products are be expected to be in stock. The sort_ord field allows the list to be presented in shortest to longest order, instead of alphabetically. See lk_avail Table Definition.

product

The product table contains all information that describes a product, including pictures, and associates each with a unique ID. This table is significantly different from the version in the AlphaSports database. See Product Table Changes.

product_category

The product_category table lists product categories and associates each with a unique ID. See Product Category Table Definition.

sales_summary_cost

The sales_summary_cost table lists number of invoices, the last invoice date, and the last invoice number for each customer. The ASWSALESHIST.A5W page runs the Xbasic copied from the sales summary by cost operation and populates the sales_summary_cost table. See Sales Summary Cost Table Definition.

sales_summary_quan

The sales_summary_quan table lists the number of units sold and the last invoice date for each product. The ASWSALESHIST.A5W page runs the Xbasic copied fromthe sales summary by quan operation and populates the sales_summary_quan table. See Sales_Summary_Quan Table Definition.

shipping_types

The shipping_types table lists shipping methods and associates each with a unique ID and base cost. See Shipping_Types Table Definition.

shop_cart

The shop_cart table lists items that customers have selected (placed in a shopping cart), but have not actually purchased. See Shop_Cart Table Definition.

shop_cart_values (set)

The shop_cart_values set links the shop_cart table (parent) one to one with the product table (child) and specials table (child).

special_sales (set)

The special_sales set links the product table (parent) links one to one with the specials table (child).

specials

The specials table lists products on sales, sale prices, and the date when each sale ends.

user_names

The user_names table contains user names, passwords, and access levels. Only internal users can access this table. See User_Names Table Definition.

vendor

The vendor table contains all information that describes a vendor. It is the same table found in the AlphaSports database.

web_reports

The web_reports table contains information necessary to run and control access to reports. See Web_Reports Table Definition.

lk_avail Table Definition

The lk_avail table contains the following fields.

Field Name

Format

Description

ship_avail

Character,20

The ship_avail field contains a description of the length of time until a product will be back in inventory.

sort_ord

Numeric,2,0

The sort_ord field provides a way to sort the table by length of time until the product will be available.

Product Table Changes

The AlphaSportsWeb product table contains all information necessary to describe and present a product to a customer. The table contains the following fields not found in the AlphaSports product table.

Field Name

Format

Description

List

Numeric,7,2

The list field contains the price of a product, as opposed to the actual (discounted) price of a product.

Cat_Id

Character,4

The cat_id field is an index into the product_category table, which contains descriptions of product categories. The relationship is defined on the Lookups tab of the cat_id field rules.

Thumbsm

Image File Reference

The thumbsm field contains a small picture of the product.

Thumb

Image File Reference

The thumb field contains a medium sized picture of the product.

Picture

Image File Reference

The picture field contains a large sized picture of the product.

Detail

Memo

The detail field contains a long description of the product.

Ship_Avail

Character,20

The ship_avail field contains the time interval until a product will be back in inventory. The relationship is defined on the Lookups tab of the ship_avail field rules.

Product_Category Table Definition

The product_category table contains the following fields.

Field Name

Format

Description

Category

Character,30

The category field contains a description of a product classification.

Cat_Id

Character,4

The cat_id field links to the cat_id field in the product table. This link enables product table layouts to display category field descriptions.

Sales_Summary_Cost Table Definition

The sales_summary_cost table contains the following fields. A summary operation populates this table.

Field Name

Format

Description

Customer_Id

Character,8

The customer_id field links to the customer_id field in the customer table.

Count_Invoice_Number

Numeric,10,0

The count_invoice_number field holds the number of purchases that a customer has made.

Last_Date

Date,8

The last_date field holds the date of the last purchase by a customer.

Last_Invoice_Number

Character,6

The last_invoice_number field holds the invoice number of the last purchase by a customer.

Sales_Summary_Quan Table Definition

The sales_summary_quan table contains the following fields. A summary operation populates this table.

Field Name

Format

Description

Product_Id

Character,12

The product_id field links to the product_id field in the product table.

Total_Quantity

Numeric,8,0

The total_quantity field contains the number of units sold for each product.

Last_Invoice_Header_Date

Date,8

The last_Invoice_Header_date field holds the date of the last product sale.

Shipping_Types Table Definition

The shipping_types table contains the following fields.

Field Name

Format

Description

Ship_Code

Character,4

The ship_code field contains a unique value used to identify each delivery method.

Delivery_By

Character,20

The delivery_by field holds a description of a delivery method.

Base_Price

Numeric,6,2

The base_price field contains the base price assigned to each delivery method.

Sort_Ord

Numeric,4,0

The sort_ord field contains a value used to order the display of the table's fields.

Shop_Cart Table Definition

The shop_cart table contains the following fields.

Field Name

Format

Description

Item_Id

Character,8

The item_id field is not used.

Session_Id

Character,40

The Application Server assigns Session_Id. Currently, WAS will use the same session ID for each browser for every access. If you close your browser and reopen, the WAS will assign the same session ID. It is used here to identify the browser used to create the cart, to show if any items were selected by the user’s browser in a previous shopping "session".

Cart_Id

Character,36

The cart_id contains a unique identifier for each collection of items selected for purchase.

Prod_Id

Character,12

The prod_id field contains the identifier for a product selected for purchase.

Owner_Id

Character,8

The owner_id field identifies the owner of the shopping cart, which is the customer ID of the user after he or she logs on.

Quantity

Numeric,5,0

The quantity field contains the number of unit of a product selected for purchase.

Open

Logical,1

The open field indicates whether a selected product has been purchased.

Ord_Date

Date,8

The ord_date field contains the date that a product was selected for purchase.

Ord_Time

Character,8

The ord_time field contains the time that a product was selected for purchase.

Specials Table Definition

The specials table contains the following fields.

Field Name

Format

Description

Product_Id

Character,12

The product_id field contains the unique identifier for a product. This field links to the product_id field of the product table.

Sale_Price

Numeric,7,2

The sale_price field contains the discounted sale price of a product.

Sale_Until

Date,8

The sale_until field contains the last date that a product is on sale.

User_Names Table Definition

The user_names table contains the following fields.

Field Name

Format

Description

User_Id

Character,8

The user_id field holds a unique ID for each user.

User_Name

Character,12

The user_name field contains the login name of a user.

Password

Character,12

The password field contains the login password of a user.

Level

Numeric,8,0

The level field contains the access level assigned to a user.

Web_Reports Table Definition

The web_reports table contains the following fields.

Field Name

Format

Description

Rpt_Id

Character,4

The rpt_id field contains a unique ID for an Alpha Five report.

Rpt_Name

Character,26

The rpt_name field contains the name of a defined Alpha Five report.

Rpt_Table

Character,26

The rpt_table field contains the name of the dictionary file that contains the report definition.

Rpt_Level

Numeric,2,0

The rpt_level field contains the minimum access level required to access a report.

See Also

AlphaSportsWeb Explained

Supported By

Alpha Five Version 7 and Above