data warehousing architecture andimplementation phần 10

Để tạo ra một báo cáo tham số, bạn phải biết bảng và tên trường của các mục dữ liệu bạn có ý định sử dụng như là các tham số vật lý. Ví dụ, nếu bạn có ý định sử dụng tháng và năm như các thông số trong báo cáo của bạn, bạn phải biết các tên bảng và tên trường cho hai tham số này | Sub MACRO_NAME on Error Resume Next Dim loVar loVar API_SetConstraint DEFAULT TABLE FIELD If Len Trim loVar 0 Then . Caption loVar End If End Sub This macro allows a user to change the constraint currently applied on a Constraint Set then displays the new constraint value on a button form. Warehouse Schema Knowledge Is Required To create a parameterized report you must know the physical table and field names of the data items you intend to use as parameters. For example if you intend to use Month and Year as parameters in your report you must know the table names and field names for these two parameters. In our sample retail schema these two fields are Parameter Table Name Field Name Month Time_Dimension Month_Name Year Time_Dimension Year_No Creating Parameterized Reports The steps required to create an Excel macro vary slightly between MS Excel 95 and MS Excel 97 because of differences in the macro programming environments of these two versions. The step-by-step instructions below indicate the differences between the two. To Create a Parameterized R olapXL Report Step 1. Create and save your basic R olapXL report. Step 2. Enter the macro programming environment of MS Excel. Excel 95 From the Insert menu choose Macro then Module. An Excel Module will be inserted as a new sheet in the same workbook. Excel 97 From the Tools menu choose Macro then Visual Basic Editor. -or- Press Alt-F11. Step 3. Create a macro reference to the R olapXL add-in. This reference is required for the APi_setconstraint function to work properly. From the Tools menu of the macro programming environment choose References. In the dialog box that appears look for R and turn on the corresponding checkbox. Click on the OK command button to close the dialog box. Step 4. Create a subroutine or macro for each field that will be used as a parameter. Excel 97 From the Insert menu of the Visual Basic Editor choose Module. Excel 95 Click on the tab of .

Không thể tạo bản xem trước, hãy bấm tải xuống
TÀI LIỆU MỚI ĐĂNG
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.