Hi,
Currently, I'm working on a SQL Server DWH.
I work on a snowflake Schema. Let say that I've on product table wich is
linked using a FK on a product grouping key to a product group label.
If I update my product refrential, this works but ...
in the real life, if a new product appears and if this grouping code doesn't
existing my loading fails.
Do you have any idea/tricks in order to load the into the product
referential adding dynamicly a new key into the grouping referential
(setting product group to a defalut value)
thk's in advance,
Renaud Harduin
Paris - France
<Renaud Harduin> wrote in message
news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Do you have any idea/tricks in order to load the into the product
> referential adding dynamicly a new key into the grouping referential
> (setting product group to a defalut value)
Default is the only way to solve this issue (other than properly
determining a product group at import time, which would be preferable).
Create an "Unknown" default group and set that as the default on your group
FK column.
|||Thk's
Renaud Harduin
"Adam Machanic" <amachanic@.air-worldwide.nospamallowed.com> a crit dans le
message de news:OYhbvx%23JEHA.2704@.TK2MSFTNGP10.phx.gbl...
> <Renaud Harduin> wrote in message
> news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Default is the only way to solve this issue (other than properly
> determining a product group at import time, which would be preferable).
> Create an "Unknown" default group and set that as the default on your
group
> FK column.
>
Showing posts with label wich. Show all posts
Showing posts with label wich. Show all posts
Wednesday, March 7, 2012
Newbie : Wharehousing Basic Question under SQL Server
Hi,
Currently, I'm working on a SQL Server DWH.
I work on a snowflake Schema. Let say that I've on product table wich is
linked using a FK on a product grouping key to a product group label.
If I update my product refrential, this works but ...
in the real life, if a new product appears and if this grouping code doesn't
existing my loading fails.
Do you have any idea/tricks in order to load the into the product
referential adding dynamicly a new key into the grouping referential
(setting product group to a defalut value)
thk's in advance,
Renaud Harduin
Paris - France<Renaud Harduin> wrote in message
news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Do you have any idea/tricks in order to load the into the product
> referential adding dynamicly a new key into the grouping referential
> (setting product group to a defalut value)
Default is the only way to solve this issue (other than properly
determining a product group at import time, which would be preferable).
Create an "Unknown" default group and set that as the default on your group
FK column.|||Thk's
Renaud Harduin
"Adam Machanic" <amachanic@.air-worldwide.nospamallowed.com> a crit dans le
message de news:OYhbvx%23JEHA.2704@.TK2MSFTNGP10.phx.gbl...
> <Renaud Harduin> wrote in message
> news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Default is the only way to solve this issue (other than properly
> determining a product group at import time, which would be preferable).
> Create an "Unknown" default group and set that as the default on your
group
> FK column.
>
Currently, I'm working on a SQL Server DWH.
I work on a snowflake Schema. Let say that I've on product table wich is
linked using a FK on a product grouping key to a product group label.
If I update my product refrential, this works but ...
in the real life, if a new product appears and if this grouping code doesn't
existing my loading fails.
Do you have any idea/tricks in order to load the into the product
referential adding dynamicly a new key into the grouping referential
(setting product group to a defalut value)
thk's in advance,
Renaud Harduin
Paris - France<Renaud Harduin> wrote in message
news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Do you have any idea/tricks in order to load the into the product
> referential adding dynamicly a new key into the grouping referential
> (setting product group to a defalut value)
Default is the only way to solve this issue (other than properly
determining a product group at import time, which would be preferable).
Create an "Unknown" default group and set that as the default on your group
FK column.|||Thk's
Renaud Harduin
"Adam Machanic" <amachanic@.air-worldwide.nospamallowed.com> a crit dans le
message de news:OYhbvx%23JEHA.2704@.TK2MSFTNGP10.phx.gbl...
> <Renaud Harduin> wrote in message
> news:4085820c$0$24993$afc38c87@.news.easynet.fr...
> Default is the only way to solve this issue (other than properly
> determining a product group at import time, which would be preferable).
> Create an "Unknown" default group and set that as the default on your
group
> FK column.
>
Newbie : Efficiency question - performance
Hi,
querying through SQL, wich gives the best result
having to look in to a large table, or looking in smaller tables but with a
lot of joins...
I'm asking this because right now, i have in my design a couple of tables
with only two or three columns, and about 10 records in each.
Would it be more interesting to add these values in my first table, and
create more records in it..Boonaap wrote:
> Hi,
> querying through SQL, wich gives the best result
> having to look in to a large table, or looking in smaller tables but
> with a lot of joins...
> I'm asking this because right now, i have in my design a couple of
> tables with only two or three columns, and about 10 records in each.
> Would it be more interesting to add these values in my first table,
> and create more records in it..
In general, you should use a relational design and only resort to
denormalization if absolutely necessary for performance. So for now I
would suggest you stick to the relational design you have and tune the
query as needed with properly designed indexes. 10 rows of data is so
small that you probably wouldn't have much of a performance issue.
David Gugick
Imceda Software
www.imceda.com|||>> Would it be more interesting to add these values in my first table, and
The number of columns in a table and the number of tables in a database are
not valid criteria for determining good designs. You may want to start by
analyzing the business model and understand the data requirements first
rather than being concerned about performance of a special query with "lots
of joins".
In general, the number of columns in a table and the number of tables in a
schema by themselves are no way related to performance. However, it may be
worthwhile to keep in mind the limitations of the DBMS, its physical
optimization variables etc which can have an effect on the performance on
some queries.
Anith
querying through SQL, wich gives the best result
having to look in to a large table, or looking in smaller tables but with a
lot of joins...
I'm asking this because right now, i have in my design a couple of tables
with only two or three columns, and about 10 records in each.
Would it be more interesting to add these values in my first table, and
create more records in it..Boonaap wrote:
> Hi,
> querying through SQL, wich gives the best result
> having to look in to a large table, or looking in smaller tables but
> with a lot of joins...
> I'm asking this because right now, i have in my design a couple of
> tables with only two or three columns, and about 10 records in each.
> Would it be more interesting to add these values in my first table,
> and create more records in it..
In general, you should use a relational design and only resort to
denormalization if absolutely necessary for performance. So for now I
would suggest you stick to the relational design you have and tune the
query as needed with properly designed indexes. 10 rows of data is so
small that you probably wouldn't have much of a performance issue.
David Gugick
Imceda Software
www.imceda.com|||>> Would it be more interesting to add these values in my first table, and
The number of columns in a table and the number of tables in a database are
not valid criteria for determining good designs. You may want to start by
analyzing the business model and understand the data requirements first
rather than being concerned about performance of a special query with "lots
of joins".
In general, the number of columns in a table and the number of tables in a
schema by themselves are no way related to performance. However, it may be
worthwhile to keep in mind the limitations of the DBMS, its physical
optimization variables etc which can have an effect on the performance on
some queries.
Anith
Labels:
database,
efficiency,
joins,
microsoft,
mysql,
newbie,
oracle,
performance,
querying,
resulthaving,
server,
sql,
table,
tables,
wich
Subscribe to:
Posts (Atom)