Showing posts with label build. Show all posts
Showing posts with label build. Show all posts

Thursday, March 29, 2012

Direct link between a camera and the database.

Where to look for a direct link between
a camera, an application (to be build) and storage
directly in a database.
(Use Identification sized pictures of customers).
Thanks for any pointers.
Ben Brugman
Hi
You may want to look at http://www.aspfaq.com/show.asp?id=2149. The method
of transferring the image to the computer may be dependent on the make of the
camera.
Binary files can be loaded in to the database (if you really want to!) using
the bii example program. As this is a sample you also have the code.
This may also be useful
http://support.microsoft.com/default...b;en-us;317034
http://support.microsoft.com/default...b;en-us;316887
John
"ben brugman" wrote:

> Where to look for a direct link between
> a camera, an application (to be build) and storage
> directly in a database.
> (Use Identification sized pictures of customers).
> Thanks for any pointers.
> Ben Brugman
>
>
sql

Direct link between a camera and the database.

Where to look for a direct link between
a camera, an application (to be build) and storage
directly in a database.
(Use Identification sized pictures of customers).
Thanks for any pointers.
Ben BrugmanHi
You may want to look at http://www.aspfaq.com/show.asp?id=2149. The method
of transferring the image to the computer may be dependent on the make of th
e
camera.
Binary files can be loaded in to the database (if you really want to!) using
the bii example program. As this is a sample you also have the code.
This may also be useful
http://support.microsoft.com/defaul...kb;en-us;317034
http://support.microsoft.com/defaul...kb;en-us;316887
John
"ben brugman" wrote:

> Where to look for a direct link between
> a camera, an application (to be build) and storage
> directly in a database.
> (Use Identification sized pictures of customers).
> Thanks for any pointers.
> Ben Brugman
>
>

Direct link between a camera and the database.

Where to look for a direct link between
a camera, an application (to be build) and storage
directly in a database.
(Use Identification sized pictures of customers).
Thanks for any pointers.
Ben BrugmanHi
You may want to look at http://www.aspfaq.com/show.asp?id=2149. The method
of transferring the image to the computer may be dependent on the make of the
camera.
Binary files can be loaded in to the database (if you really want to!) using
the bii example program. As this is a sample you also have the code.
This may also be useful
http://support.microsoft.com/default.aspx?scid=kb;en-us;317034
http://support.microsoft.com/default.aspx?scid=kb;en-us;316887
John
"ben brugman" wrote:
> Where to look for a direct link between
> a camera, an application (to be build) and storage
> directly in a database.
> (Use Identification sized pictures of customers).
> Thanks for any pointers.
> Ben Brugman
>
>

Tuesday, March 27, 2012

Dimension with two names for each Key

Hi!

I need to build a dimension that offers two names for each entry.

For example, I have an electronics sparepart, a simple resistor that is called "abc-xy-12345" as company internal part number and also maybe "Resistor 1.0 kOhm 0.5 W" for a human being. Finally, for me as database guy, this part is a 4 byte integer number, I understand this is preferred to using the 15 byte part number. The dimension will have around 10,000 members when fully loaded, if that is important for the decision how to do it.

So I need to have a dimension that allows some of the users need to see the part as part number since they need to do a VLOOKUP in Excel or similar with the data, while the other usergroups needs to build a report upon the data, and they want to see a "self speaking name".

I do not want to build two nearly identical dimensions, what other way can I use to accomplish this?

If I add the order number to the text property of the key attribute and have another attribute on the long clear name, should this attribute be based on the integer for key as well and use name for the text?

Hi Ralf,

maybe the fastest way is create two attribute both with Key = your integer code.

One with Name = Company Part Number Name and the other with Name = Self Speaking Name

Francesco

|||

I was thinking that too, but where do you set the Key attribute to (the one that is displayed with the little golden key) for the dimension onto?

Anyone of the two, does not matter? Or have the ID alone (invisible) as the key as "anchor" and add the two names each as attribute?

|||

Hi Ralf,

the attribute with the little golden key is the attribute that has Set Attribute Usage = Key (right click on the attribute to check). It's used by AS as "unique key" in the dimension and in your case it has KeyColumn = your integer key code column .

Because both your attribute are at the lowest granularity in your dimension (1 member for every integer key code), you can:

use the one with Set Attribute Usage = Key (the one with the little golden key) with NameColumn set to the column you prefer (Company Part Number Name or Self Speaking Name)

then add another attribute (with Set Attribute Usage = Regular) with KeyColumn = your integer key code column and NameColumn = the other description you have.

Francesco

Sunday, March 25, 2012

dimension security doesn't work when you use {}

I think this is a bug, but I want to check that I've understood the expected behavior before reporting it.

1. Build a Geography dimension where the key attribute is City. Also add a State attribute.

2. Define dimension security for the Geography.City attribute and make the allowed set {Geography.City.Dallas}

3. When I run an MDX query with Geography.City.Members it returns only Dallas as expected

4. When I run an MDX query with Geography.State.Members it returns only Texas as expected.

5. Change the allowed set for Geography.City to be {} (that is, empty set)

6. When I run an MDX query with Geography.City.Members is returns empty set as expected

7. When I run an MDX query with Geography.State.Members is returns ALL STATES!! Is this a bug?

The real scenario behind this is dynamic security. If the allowed set MDX expression returns empty set, then I get the behavior described in step 7 for all the non-key attributes in that dimension. The only way I've been able to workaround this is to change the expression to return some bogus member like [Geography].[City].&[DOES NOT EXIST] instead of empty set. (Or I can make the allowed set on all attributes {})

I beleive that what you observe is the designed behavior of the system. I don't beleive that you will be able to use [Geography].[City].&[DOES NOT EXIST] instead of empty set, since inside dimension security MdxMissingMemberMode is always set to Error, so you will get error instead. I beleive that your scenario with dynamic security will work fine though, as long as expressions for allowed set preserve hierarchility properly, even if they result in empty set.|||

I want to use empty set. However I do not get the desired results (allowing this user to see no members of a dimension) when I use empty set.

However, when I use [Geography].[City].&[DOES NOT EXIST] then I DO get the desired results. I can't explain why it works, but it does.

Wednesday, March 21, 2012

Difficult Query. Is it possible?

Hi,

I am looking for a type of aggregate function for a string. Instead of finding a Max value or the average of a column, I would like to build one string value holding the aggregate.

Example:

Source data

RecordID PersonID Name Course Score

1 1 Fred Maths 70

2 1 Fred Science 78

3 2 Mary Maths 65

4 2 Mary Science 60

5 2 Mary History 85

I would like my query to return the following resultset:

Name Scores

Fred 70; 78

Mary 65; 60; 85

Hi R2 DJ,

In your ASP.NET Application, using DataGrid web server control and implementing ItemDataBound event.

Good Coding!

Javier Luna
http://guydotnetxmlwebservices.blogspot.com/

|||

You could use UDF's, but there are some limitations/dificulties.

For instance, the next sample is simple, but will only work for response sizes until varchar (max). You could do the same with text, but it would be a little bit more complicated:

create FUNCTION dbo.ConcatenateEmployeeCustomers

(

-- Add the parameters for the function here

@.iIDEmployee int

)

RETURNS varchar ( max )

AS

BEGIN

declare @.vcTotal as varchar (max )

set @.vcTotal = ''

select @.vcTotal = @.vcTotal + ISNULL ( CustomerID + ',' , '')

From orders

where EmployeeID = @.iIDEmployee

RETURN @.vcTotal

END

GO

select dbo.ConcatenateEmployeeCustomers ( EmployeeID ) , *

from employees

|||

In SQL Server 2005, you can do this using XML. For

your case, it would look something like this:

-- Adapted from an example posted by Erland Sommarskog

select

Name,

substring(IdList, 1, datalength(IdList)/2 - 1)

-- strip the last ',' from the list

from (

select distinct Name from YourTable

) as c -- or use a Names table if one exists

cross apply (

select

convert(nvarchar(30), PersonID) + ',' as [text()]

from YourTable as o

where o.PersonID = c.PersonID

order by o.RecordID

for xml path('')

) as Dummy(IdList)

Steve Kass

Drew University

www.stevekass.com

R2 DJ@.discussions.microsoft.com wrote:

> Hi,

>

> I am looking for a type of aggregate function for a string. Instead of

> finding a Max value or the average of a column, I would like to build

> one string value holding the aggregate.

>

> Example:

>

> Source data

>

> RecordID PersonID Name Course

> Score

>

> 1 1 Fred

> Maths 70

>

> 2 1 Fred

> Science 78

>

> 3 2 Mary

> Maths 65

>

> 4 2 Mary

> Science 60

>

> 5 2 Mary

> History 85

>

> I would like my query to return the following resultset:

>

> Name Scores

>

> Fred 70; 78

>

> Mary 65; 60; 85

>

>

Monday, March 19, 2012

Differents DataSets

hi,

i have to build a cube with the following data:

- a part monthly agregated and
- a part yearly agregated.

how could i do this ?

thanks.

The usual approach is to create two different measure groups in the cube.

The first measure group would have Time granularity defined on the Month attribute, and would contain a partition based on your SQL table with monthly aggregated data.

The second measure group would similarly have granularity on Year (instead of Month), and have a partition based on the other SQL table...

Hope this helps