R******d 发帖数: 1436 | 1 请看网上的列子:
http://courses.ttu.edu/isqs5349-westfall/images/5349/Multivaria
proc mixed method=reml; /* Performs Multivariate Regression Analysis */
/* Identical to separate OLS models */
/* Method=REML is "restricted" ML, adjusted for df
*/
class cartype month;
model sales = cartype cartype*ppggas cartype*intinv/noint s ddfm=satterth;
repeated /subject=month type=un r=1 rcorr=1;
run;
如果写成:
class cartype;
repeated cartype/subject=month typ... 阅读全帖 |
|
f***e 发帖数: 17 | 2 我define 了table department,里面有nested table cars,现在怎么count 一共
有多少cars for all departments.
create or replace type CARTYPE as object
(
VIN NUMBER(17),
YEAR NUMBER(4),
MODEL VARCHAR2(60)
);
/
create or replace type CARTABLETYPE as table of CARTYPE;
/
create table Dept(
deptID integer constraint dept_pk primary key,
dname char(20) not null,
cars CartableType
)
nested table cars store as Cartable;
然后我用:
select sum(count(c.*)) from dept D,table(d.cars) c; |
|
|
|
|