Showing posts with label associated. Show all posts
Showing posts with label associated. Show all posts

Tuesday, March 20, 2012

Association Prediction by Rules Still Returns Itemsets

If I use this code with an association model, it still returns itemsets for me - when it should be returning only nodes with rules associated with them (according to sqlserverdatamining.com). If I try adding 'AND $PROBABILITY > .25' to the where clause, it returns 0 results for every query I try. Any clue why this may be happening?

Code Snippet

SELECT FLATTENED
(SELECT * FROM PredictAssociation([Product],20,
INCLUDE_NODE_ID,INCLUDE_STATISTICS)
WHERE $NODEID<>'')
FROM
[ProductRecommend]
PREDICTION JOIN
OPENQUERY([ds],
'SELECT
[PRODUCTCLASSID],[DESCRIPTION]
FROM
[Product_Table]
WHERE
[PRODUCTCLASSID] = ''1234'' AND [DESCRIPTION] = ''DESC''
') AS t

ON
[ProductRecommend].[Product].[PRODUCTCLASSID] = t.[PRODUCTCLASSID] AND
[ProductRecommend].[Product].[DESCRIPTION] = t.[DESCRIPTION]

This query returns more relevant results than those lacking the filtering by $NODEID, however the results should have higher probabilities than .047! Please help! Thanks!

Okay, I just reconstructed the same query using my data in a relational mining model (instead of OLAP) and got reasonable results. Would anyone know how to fix this for OLAP or be able to point me in a direction where I could go to learn how to do it? Thanks.

|||What is the MINIMUM_PROBABILITY value for the OLAP mining model?
Is it different than the one from the relational model?

One more thing (which you probably know already) -- the query you posted initially executes one prediction (PredictAssociation ... 20) for each row in the data source query (does not group together multiple input rows belonging to the same transaction).
Basically, only rules having a single item on the left hand side will be used in prediction.

Associating mdf and ldf files to databases

Is there some sort of command that can tell me which mdf and ldf files are associated to which databases?

Thanks,
Ninel

There are many ways to get the information depending on the version of SQL Server. You can query the following tables/views:

master.dbo.sysaltfiles (SQL Server 2000)

sys.master_files (SQL Server 2005)

To look at individual databases only, you can use the system stored procedure "sp_helpdb" in any version of SQL Server.

associated xsl file will not format working xml template

I am just trying to get (what I thought was) a simple xsl file to
format (--> HTML) a simple xml query specified in a template file.
I do not get any message in the browser (except: page not found) or in
the Windows event viewer.
I am able to execute a URL query with no problems.
I am able to execute the template query.
When I specifiy the xsl file, no information appears.
I would like to know where/how this type of problem can be debugged.
I would be happy to post the short xml and xsl file here if that could
illuminate this problem.
TIA.
Regards..
"Relishguy" <dbsearch04@.yahoo.com> wrote in message
news:84e6fe3d.0406140716.15af040a@.posting.google.c om...
[snip]
> I would like to know where/how this type of problem can be debugged.
The best way to debug this type of problem is to debug the xsl since that is
usually where the problem is. You can post it here if you want and I would
also suggest saving an XML file that has the results from your query and
then linking the stylesheet to it and opening it in IE.
Bryant
sql