Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
unstable
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PROINFODATA
unstable
Commits
bbc5caef
Commit
bbc5caef
authored
12 years ago
by
Marcelo Lacerda
Browse files
Options
Downloads
Patches
Plain Diff
Fixed regression where invalid entries where inserted in the inventory
Signed-off-by:
Marcelo Lacerda
<
msl09@c3sl.ufpr.br
>
parent
083487d6
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
database/load/002-dim_inventory.sql
+2
-1
2 additions, 1 deletion
database/load/002-dim_inventory.sql
database/load/003-fact_contact.sql
+1
-1
1 addition, 1 deletion
database/load/003-fact_contact.sql
with
3 additions
and
2 deletions
database/load/002-dim_inventory.sql
+
2
−
1
View file @
bbc5caef
...
@@ -35,7 +35,8 @@ BEGIN
...
@@ -35,7 +35,8 @@ BEGIN
s
.
disk2_model
=
d
.
disk2_model
AND
s
.
disk2_model
=
d
.
disk2_model
AND
s
.
disk2_size
>=
d
.
disk2_size
*
0
.
9
AND
s
.
disk2_size
>=
d
.
disk2_size
*
0
.
9
AND
s
.
disk2_size
<=
d
.
disk2_size
*
1
.
1
AND
s
.
disk2_size
<=
d
.
disk2_size
*
1
.
1
AND
s
.
disk2_used
=
d
.
disk2_used
)
LOOP
s
.
disk2_used
=
d
.
disk2_used
)
WHERE
valid
=
'1'
LOOP
-- IF .... THEN
-- IF .... THEN
...
...
This diff is collapsed.
Click to expand it.
database/load/003-fact_contact.sql
+
1
−
1
View file @
bbc5caef
...
@@ -16,7 +16,7 @@ BEGIN
...
@@ -16,7 +16,7 @@ BEGIN
--
--
INSERT
INTO
fact_contact
(
sch_id
,
cit_id
,
dat_id
,
macaddr
)
INSERT
INTO
fact_contact
(
sch_id
,
cit_id
,
dat_id
,
macaddr
)
(
SELECT
sch_id
,
cit_id
,
contact_date
,
macaddr
::
macaddr
FROM
sa_inventory
)
(
SELECT
sch_id
,
cit_id
,
contact_date
,
macaddr
::
macaddr
FROM
sa_inventory
WHERE
valid
=
'1'
)
EXCEPT
EXCEPT
(
SELECT
sch_id
,
cit_id
,
dat_id
,
macaddr
FROM
fact_contact
WHERE
dat_id
>=
result
.
min_date
AND
dat_id
<=
result
.
max_date
);
(
SELECT
sch_id
,
cit_id
,
dat_id
,
macaddr
FROM
fact_contact
WHERE
dat_id
>=
result
.
min_date
AND
dat_id
<=
result
.
max_date
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment