Showing posts with label numbers. Show all posts
Showing posts with label numbers. Show all posts

Wednesday, March 7, 2012

custom Discretization patterns

I have a problem with setting a reasonable Discretization pattern on some dimensions.

One of my dimensions has int numbers scattered from 400 to 900. another dimension has float numbers from 0 to 100, however Automatic discretization does not create even ranges for example 0-100,100-200,etc nor 0-10, 10-20, etc. I tried setting DiscretizationBucketCounts to 10,20,100 etc, however, AS does not create rounded bounds for the buckets.

Since the analisys applications are mostly for use by humans, it would make sense to add support for human-readable discretization, like is done in Excel Charts, etc.

Is there a way to setup my own discretization pattern (other than changing the data view to Query with a bunch of Case statements?) ?

From the ASSL documentation in SQL Server 2005 BOL, it looks like an "EqualRanges" discretization method was envisaged, which might have met your needs. Unfortunately, it doesn't seem to have been implemented (as of SP1), at least for DimensionAttribute:

http://msdn2.microsoft.com/en-us/library/ms127037.aspx

>>

SQL Server 2005 Books Online

DiscretizationMethod Element (ASSL)

Defines the method to be used for discretization.

...

Relationship Element

Parent elements

DimensionAttribute, ScalarMiningStructureColumn

...

EqualRanges

Equivalent to the EQUAL_RANGES discretization method for mining structure columns.

>>

|||

I tried other discretization methods, - Automatic, Clusters, Equal Ranges.

they all seem to group members on odd intervals, like 12.3-13.5, 13.5-14.6, etc.

Friday, February 24, 2012

Custom code executed when user exports to PDF

Hi,

Is there a way to execute custom code when a user exports a report to PDF? I have an assembly that writes the pages numbers to a database table in order to create a Table of contents. This works great except that the code is called when the report is initially created so the page numbers are written to the database. Then when the user clicks to export to PDF, the PDF page numbers (the ones I want to keep) are written to the database and conflict with the first set of page numbers. Is there any way that I can only call the custom assembly with the export to pdf option is chosen? Or execute code that will truncate the table before exporting to PDF?

Any suggestions?

Thanks in advance,

Amy Bolden

Chosen from where? If this is a custom application and use the ReportViewer controls, you could sink the ReportExport event. You can always call a stored procedure that preps the database too.

Tuesday, February 14, 2012

Custom application advice

Hi,
I have made a custom web application using .asp and an
Access 2000 backend database. This application allows
users to enter reference numbers. Once reference numbers
are entered, a list is generated to be run on an external
database to get account information for the account
reference in question. By this I mean the account
holder's name, address, postcode etc...
Next, I have to import this back into the database so that
the database is enriched with more information. Staff
then work on the records, phoning customers to make sure
details are correct etc... If details are not correct,
then amendments are made on screen and saved to the
database along with the original record. This is to show
what the original record looked like and the revised
version - if there were any changes.
My problem at the moment is getting the whole thing going
for real as the setup is a test. I want to migrate to
SQL2000 and make this application run in a live
environment so that I can upload the enriched files on a
daily basis quickly and easily. Furthermore, it has been
discussed whether I can upload enriched data (maybe a .txt
file) onto the main database using a file upload facility -
is this possible?
At the moment, this is how my system works - which is
still at trial stage, so I would not mind any comments on
improvement:
1. Enter customer references. This gets posted into a
table with a timestamp, user's name (for tracking)
2. I then generate a list of two or more occurences of the
customer references. This part I am unsure about,
particularly when my list of two or more would have
different ID numbers from the records in my original table!
3. Once an external enrichment process has occurred, then
I import and overwrite the entire table (is this right?)
4. Staff can then search for and lookup the enriched data
by entering a customer reference. There is then a form
beside the original data, where they can post any
amendments.
5. Amendments are then created as a new record inthe
table, flagged as 'Amendment' and the original record
flagged as 'Original'.
6. A list can then be produced showing the Original Data
and Amendments on fields that have been amended.
Help will be appreciated.
Thanks.
SKC
The newsgroups aren't really the best venue for designing entire
applications. However, if this is a web application, I'd recommend
that you explore using asp.net, where you can work more easily with
XML and SQL Server. www.gotdotnet.com is a great source of more
information, tutorials, and samples to get you started.
--Mary
On Wed, 1 Sep 2004 02:15:16 -0700, "skc"
<anonymous@.discussions.microsoft.com> wrote:

>Hi,
>I have made a custom web application using .asp and an
>Access 2000 backend database. This application allows
>users to enter reference numbers. Once reference numbers
>are entered, a list is generated to be run on an external
>database to get account information for the account
>reference in question. By this I mean the account
>holder's name, address, postcode etc...
>Next, I have to import this back into the database so that
>the database is enriched with more information. Staff
>then work on the records, phoning customers to make sure
>details are correct etc... If details are not correct,
>then amendments are made on screen and saved to the
>database along with the original record. This is to show
>what the original record looked like and the revised
>version - if there were any changes.
>My problem at the moment is getting the whole thing going
>for real as the setup is a test. I want to migrate to
>SQL2000 and make this application run in a live
>environment so that I can upload the enriched files on a
>daily basis quickly and easily. Furthermore, it has been
>discussed whether I can upload enriched data (maybe a .txt
>file) onto the main database using a file upload facility -
> is this possible?
>At the moment, this is how my system works - which is
>still at trial stage, so I would not mind any comments on
>improvement:
>1. Enter customer references. This gets posted into a
>table with a timestamp, user's name (for tracking)
>2. I then generate a list of two or more occurences of the
>customer references. This part I am unsure about,
>particularly when my list of two or more would have
>different ID numbers from the records in my original table!
>3. Once an external enrichment process has occurred, then
>I import and overwrite the entire table (is this right?)
>4. Staff can then search for and lookup the enriched data
>by entering a customer reference. There is then a form
>beside the original data, where they can post any
>amendments.
>5. Amendments are then created as a new record inthe
>table, flagged as 'Amendment' and the original record
>flagged as 'Original'.
>6. A list can then be produced showing the Original Data
>and Amendments on fields that have been amended.
>Help will be appreciated.
>Thanks.
>SKC