Showing posts with label working. Show all posts
Showing posts with label working. Show all posts

Thursday, March 22, 2012

bug? outlook web access

Scenerio:
RS2000. Subscription delivers email with PDF attachment.
When the email is opened in Outlook client, the attachment is there and
working as expected.
Problem:
When the email is opened in the Outlook Web client (OWA), the paperclip is
there identifying the attachment, but when the email is opened, there is no
attachment.
It seems to be happening only with attachment coming from reporting
services. I can send an email with another PDF file and open it fine. The
PDF files are small in size so I do not think it is a size proble.I just tried this and also was not able to see the .pdf file. This appears
to be a bug to me. I would contact customer support to help get this issue
resolved.
--
-Daniel
This posting is provided "AS IS" with no warranties, and confers no rights.
"chicagoclone" <chicagoclone@.discussions.microsoft.com> wrote in message
news:B4C39492-DC1A-4FA0-8198-F1727A020B34@.microsoft.com...
> Scenerio:
> RS2000. Subscription delivers email with PDF attachment.
> When the email is opened in Outlook client, the attachment is there and
> working as expected.
> Problem:
> When the email is opened in the Outlook Web client (OWA), the paperclip is
> there identifying the attachment, but when the email is opened, there is
> no
> attachment.
> It seems to be happening only with attachment coming from reporting
> services. I can send an email with another PDF file and open it fine.
> The
> PDF files are small in size so I do not think it is a size proble.|||Daniel,
Thank you for the response.
"Daniel Reib [MSFT]" wrote:
> I just tried this and also was not able to see the .pdf file. This appears
> to be a bug to me. I would contact customer support to help get this issue
> resolved.
> --
> -Daniel
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "chicagoclone" <chicagoclone@.discussions.microsoft.com> wrote in message
> news:B4C39492-DC1A-4FA0-8198-F1727A020B34@.microsoft.com...
> >
> > Scenerio:
> > RS2000. Subscription delivers email with PDF attachment.
> > When the email is opened in Outlook client, the attachment is there and
> > working as expected.
> >
> > Problem:
> > When the email is opened in the Outlook Web client (OWA), the paperclip is
> > there identifying the attachment, but when the email is opened, there is
> > no
> > attachment.
> >
> > It seems to be happening only with attachment coming from reporting
> > services. I can send an email with another PDF file and open it fine.
> > The
> > PDF files are small in size so I do not think it is a size proble.
>
>

Tuesday, March 20, 2012

BUG: SET FMTONLY not working on SQL Server 2000

Hello
I have reported this bug previosly, but Microsoft has so far not responded yet, so I am reporting it again. Basicly, SET FMTONLY is NOT working correctly with SQL Server 2000. Because of this bug I still have to use SQL Server 7.0 for my campuswide student information system application, although I really would like to upgrade to SQL Server 2000 :-
Here's the script to reproduce the bug
-- create the test tables, and populate the
Create Table dbo.USERS_TES
([USER_ID] int PRIMARY KEY not null
[NAME] varchar(20) null
[SURNAME] varchar(20) null
G
Set NoCount O
Insert Into dbo.USERS_TEST Values (1,'Bulent','Biyikoglu'
Insert Into dbo.USERS_TEST Values (2,'Jane','Doe'
G
Create Table dbo.USER_DETAILS_TES
([USER_DETAIL_ID] int PRIMARY KEY not null
[USER_ID] int NOT NULL FOREIGN KEY REFERENCES dbo.USERS_TEST([USER_ID])
FATHERS_NAME varchar(20) null
MOTHERS_NAME varchar(20) null
PLACE_OF_BIRTH varchar(40) null
CITY varchar(20) null
TOWN varchar(20) null
COUNTRY varchar(20) null
G
Set NoCount O
Insert Into dbo.USER_DETAILS_TEST Values (1,1,'Father1','Mother1','Polatli','Palo Alto','Stanford','Turkey'
Insert Into dbo.USER_DETAILS_TEST Values (2,2,'Father2','Mother2','Orange County','Los Angeles','Berkeley','USA'
G
SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
G
-- create the stored procedure that accesses the test table
/****** Object: Stored Procedure dbo.GetUserDetailsTest Script Date: 27.11.2002 00:57:27 ******
CREATE PROCEDURE [GetUserDetailsTest
(@.UserId int = Null
@.UserDetailId int = Null
@.ExpansionType tinyint = 0
A
Set NoCount O
If @.ExpansionType = Begi
If @.UserDetailId Is Not Nul
Begi
Select
ud.USER_DETAIL_ID
ud.USER_ID
ud.FATHERS_NAME
ud.MOTHERS_NAME
ud.PLACE_OF_BIRTH
ud.CITY
ud.TOWN
ud.COUNTR
From dbo.USER_DETAILS_TEST u
Where ud.USER_DETAIL_ID = @.UserDetailI
Return
En
If @.UserId Is Not Nul
Begi
Select
ud.USER_DETAIL_ID
ud.USER_ID
ud.FATHERS_NAME
ud.MOTHERS_NAME
ud.PLACE_OF_BIRTH
ud.CITY
ud.TOWN
ud.COUNTR
From dbo.USER_DETAILS_TEST u
Where ud.USER_ID = @.UserI
Return
En
En
If @.ExpansionType = Begi
If @.UserId Is Not Nul
Begi
Select
u.USER_ID
u.[NAME]
u.[SURNAME]
ud.USER_DETAIL_ID
ud.FATHERS_NAME
ud.MOTHERS_NAME
ud.PLACE_OF_BIRTH
ud.CITY
ud.TOWN
ud.COUNTR
From dbo.USER_DETAILS_TEST u
Inner Join dbo.USERS_TEST u On ud.USER_ID = u.USER_I
Where u.USER_ID = @.UserI
Return
En
En
G
SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
G
-- use SET FMTONLY to return metadata, HERE's WHERE THE BUG OCCURS
-- the procedure is called as if @.ExpansionType parameter is set to
set fmtonly on exec GetUserDetailsTest @.UserId=1,@.ExpansionType=1 set fmtonly of
exec GetUserDetailsTest @.UserId=1,@.ExpansionType=Ignore this if you are posting from the MSDN managed groups:
This is not a formal bug reporting forum. This is a peer to peer forum,. To
report a bug formally, open a case with MS. You will not be charged if it is
a bug.
--
Tibor Karaszi, SQL Server MVP
Archive at:
http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Bulent Biyikoglu, MCSD" <bulent@.e-kampus.com> wrote in message
news:DDE055D6-D61D-49AF-B6F9-7615EA12E9A6@.microsoft.com...
> Hello,
> I have reported this bug previosly, but Microsoft has so far not responded
yet, so I am reporting it again. Basicly, SET FMTONLY is NOT working
correctly with SQL Server 2000. Because of this bug I still have to use SQL
Server 7.0 for my campuswide student information system application,
although I really would like to upgrade to SQL Server 2000 :-(
> Here's the script to reproduce the bug:
> -- create the test tables, and populate them
> Create Table dbo.USERS_TEST
> ([USER_ID] int PRIMARY KEY not null,
> [NAME] varchar(20) null,
> [SURNAME] varchar(20) null)
> GO
> Set NoCount On
> Insert Into dbo.USERS_TEST Values (1,'Bulent','Biyikoglu')
> Insert Into dbo.USERS_TEST Values (2,'Jane','Doe')
> GO
> Create Table dbo.USER_DETAILS_TEST
> ([USER_DETAIL_ID] int PRIMARY KEY not null,
> [USER_ID] int NOT NULL FOREIGN KEY REFERENCES dbo.USERS_TEST([USER_ID]),
> FATHERS_NAME varchar(20) null,
> MOTHERS_NAME varchar(20) null,
> PLACE_OF_BIRTH varchar(40) null,
> CITY varchar(20) null,
> TOWN varchar(20) null,
> COUNTRY varchar(20) null)
> GO
> Set NoCount On
> Insert Into dbo.USER_DETAILS_TEST Values
(1,1,'Father1','Mother1','Polatli','Palo Alto','Stanford','Turkey')
> Insert Into dbo.USER_DETAILS_TEST Values (2,2,'Father2','Mother2','Orange
County','Los Angeles','Berkeley','USA')
> GO
> SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
> GO
> -- create the stored procedure that accesses the test tables
> /****** Object: Stored Procedure dbo.GetUserDetailsTest Script Date:
27.11.2002 00:57:27 ******/
> CREATE PROCEDURE [GetUserDetailsTest]
> (@.UserId int = Null,
> @.UserDetailId int = Null,
> @.ExpansionType tinyint = 0)
> As
> Set NoCount On
> If @.ExpansionType = 0
> Begin
> If @.UserDetailId Is Not Null
> Begin
> Select
> ud.USER_DETAIL_ID,
> ud.USER_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Where ud.USER_DETAIL_ID = @.UserDetailId
> Return 0
> End
> If @.UserId Is Not Null
> Begin
> Select
> ud.USER_DETAIL_ID,
> ud.USER_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Where ud.USER_ID = @.UserId
> Return 0
> End
> End
> If @.ExpansionType = 1
> Begin
> If @.UserId Is Not Null
> Begin
> Select
> u.USER_ID,
> u.[NAME],
> u.[SURNAME],
> ud.USER_DETAIL_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Inner Join dbo.USERS_TEST u On ud.USER_ID = u.USER_ID
> Where u.USER_ID = @.UserId
> Return 0
> End
> End
> GO
> SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
> GO
> -- use SET FMTONLY to return metadata, HERE's WHERE THE BUG OCCURS:
> -- the procedure is called as if @.ExpansionType parameter is set to 0
> set fmtonly on exec GetUserDetailsTest @.UserId=1,@.ExpansionType=1 set
fmtonly off
> exec GetUserDetailsTest @.UserId=1,@.ExpansionType=1
>|||Bulent Biyikoglu, MCSD wrote:
> Hello,
> I have reported this bug previosly, but Microsoft has so far not
> responded yet, so I am reporting it again. Basicly, SET FMTONLY is
> NOT working correctly with SQL Server 2000. Because of this bug I
> still have to use SQL Server 7.0 for my campuswide student
> information system application, although I really would like to
> upgrade to SQL Server 2000 :-(
> Here's the script to reproduce the bug:
> -- create the test tables, and populate them
> Create Table dbo.USERS_TEST
> ([USER_ID] int PRIMARY KEY not null,
> [NAME] varchar(20) null,
> [SURNAME] varchar(20) null)
> GO
> Set NoCount On
> Insert Into dbo.USERS_TEST Values (1,'Bulent','Biyikoglu')
> Insert Into dbo.USERS_TEST Values (2,'Jane','Doe')
> GO
> Create Table dbo.USER_DETAILS_TEST
> ([USER_DETAIL_ID] int PRIMARY KEY not null,
> [USER_ID] int NOT NULL FOREIGN KEY REFERENCES
> dbo.USERS_TEST([USER_ID]), FATHERS_NAME varchar(20) null,
> MOTHERS_NAME varchar(20) null,
> PLACE_OF_BIRTH varchar(40) null,
> CITY varchar(20) null,
> TOWN varchar(20) null,
> COUNTRY varchar(20) null)
> GO
> Set NoCount On
> Insert Into dbo.USER_DETAILS_TEST Values
> (1,1,'Father1','Mother1','Polatli','Palo Alto','Stanford','Turkey')
> Insert Into dbo.USER_DETAILS_TEST Values
> (2,2,'Father2','Mother2','Orange County','Los
> Angeles','Berkeley','USA') GO
> SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
> GO
> -- create the stored procedure that accesses the test tables
> /****** Object: Stored Procedure dbo.GetUserDetailsTest Script
> Date: 27.11.2002 00:57:27 ******/ CREATE PROCEDURE
> [GetUserDetailsTest] (@.UserId int = Null,
> @.UserDetailId int = Null,
> @.ExpansionType tinyint = 0)
> As
> Set NoCount On
> If @.ExpansionType = 0
> Begin
> If @.UserDetailId Is Not Null
> Begin
> Select
> ud.USER_DETAIL_ID,
> ud.USER_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Where ud.USER_DETAIL_ID = @.UserDetailId
> Return 0
> End
> If @.UserId Is Not Null
> Begin
> Select
> ud.USER_DETAIL_ID,
> ud.USER_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Where ud.USER_ID = @.UserId
> Return 0
> End
> End
> If @.ExpansionType = 1
> Begin
> If @.UserId Is Not Null
> Begin
> Select
> u.USER_ID,
> u.[NAME],
> u.[SURNAME],
> ud.USER_DETAIL_ID,
> ud.FATHERS_NAME,
> ud.MOTHERS_NAME,
> ud.PLACE_OF_BIRTH,
> ud.CITY,
> ud.TOWN,
> ud.COUNTRY
> From dbo.USER_DETAILS_TEST ud
> Inner Join dbo.USERS_TEST u On ud.USER_ID = u.USER_ID
> Where u.USER_ID = @.UserId
> Return 0
> End
> End
> GO
> SET QUOTED_IDENTIFIER OFF SET ANSI_NULLS ON
> GO
> -- use SET FMTONLY to return metadata, HERE's WHERE THE BUG OCCURS:
> -- the procedure is called as if @.ExpansionType parameter is set to 0
> set fmtonly on exec GetUserDetailsTest @.UserId=1,@.ExpansionType=1 set
> fmtonly off
> exec GetUserDetailsTest @.UserId=1,@.ExpansionType=1
/*Hi Bulent, while I am certainly not going to dispute that the
behaviour using this command in SQL 7 does do what you expect (since I
cant test it against 7 at the mo), I think this behaviour in 2000 is by
design.
As you know the SET FMTONLY ON setting is telling SQL to return only
the metadata of a result set. It appears that all statements that do
not return a result set and metadata are processed only but then
ignored (if that makes sense! since you have effectively told SQL that
you are only interested in the metadata) INCLUDING logic statements.
See the following*/
USE Northwind
SET NOCOUNT OFF
DECLARE @.myInt TINYINT
SET @.myInt=1
--SET FMTONLY ON
PRINT 'Display this text from print. You will see it does not print'
SELECT 'Display this text from select. You will see it is processed BUT
the result set contains no metadata'
SELECT @.myInt=2 --You will see below (from print) that this select is
processed
SET FMTONLY OFF PRINT @.myInt SET FMTONLY ON
SET @.myInt=3 --You will see below (from print) that this set is
processed
SET FMTONLY OFF PRINT @.myInt SET FMTONLY ON
select * from northwind..orders
select * from northwind..[order Details]
IF @.myInt=1 --is skipped
select * from northwind..orders --meta is returned
ELSE --is skipped
select * from northwind..[order Details] --meta is returned
ENDIF
EXEC SP_HELP --Stored procedure with multiple Selects including
variable assignments all metadata selects are returned
SELECT * FROM Northwind..Invoices --This is a view, metadata is returned
SET FMTONLY OFF
Br,
Mark Broadbent
mcdba , mcse+i
=============sql

Sunday, February 12, 2012

Boy am in big trouble!

I just got finished developing the company intranet site and thinking that everything was working I boasted about how good it was by getting my boss to login and submit a new job to the db (new job, its a work management app) while i did the same, the pland was to hit the submit button at the same time. He would send one to be read by me and I would send one to be read by him. We both hit submit and the following happened.

The db has somehow fused the two into one. I thought maybe we were to accurate in hitting the submit button together. But I even gave a five second delay between and for some reason the job is being overriden by one user tor the other. In other words we are both sharing the same jobid. I thought this could never happen with sql server supposing that it would lock one request until another was completed and vice versa. But I'm so new to this that I'm just so naieve to think that the db would do this for you. Problem is I'm about to move on and I can't leave the app in this state. Can anyone point to some articles or give some suggestions has to my situation. Most desperately in need!!

Thanks in advanceoh crap. that's insane man. what's the db architecture, and are you using procedures to do the transactions? need more info. it shouldn't allow multiple inserts to be merged into one unless you're using a datatable to hold the data, and you're doing that incorrectly.|||In fact, if you want, just aim me in the morning. PST, and I'll help you out then, and post the logs here.|||I use stored procedures and transactions.

Where do i get the logs?|||Nevermind. Actually.. I can't see how this is happening.

In fact, it's impossible unless you're creating the primary key manually, or trying to do something uncommonly complicated, and messed up along the way.|||This is what I'm doing and It makes sense why it doing this but I'm not sure of a solution.

Let me explain.

I have two processes.

I add a job to my db, the job contains a title, date, time etc.

When the user submits it they are returned a job number from the db. They then need to add a note that goes along with the job. This job is stored in a job table

A job can have many notes but they must add at least one, thats the default behaviour. When having submitted the note the details are stored in a note table, its foreign key is the jobid that was returned from the first insert.

IE I can access all the notes by its jobid.

The problem occurs when two people do this

User A : Adds a job

User B : Adds a job

I think user a's jobid is being written over by user b. Therefore when (user a) add a note they are actually submitting the note to the jobid of user b.

Now thats my hunch. And it certainly explains the behaviour. Problem is that I can't really afford to change the structure of the entire thing right now. What would really help is if I was able to prevent (user a's) job number from being over written. I'm using static vars.

Any suggestions would be most helpful!!|||dont you have a username/userid column tht you can use to differentiate among users ?|||I'm going to go on a limb, and assume the JobID foriegn key is an int - Identity with an increment seed of 1 right?|||I found the problem and it had nothing to do with my db. I was using a property to store my jobid, which meant that the last person to add a new job would be overwritting the previous persons job id. If user a had'nt submitted is note before user b added a new job the user a's job id would be overwritten by users b's. So user a would be submitting a note with a foreign keys from user b.

Now I know what going on I am kinda on the road to recovery.

I just need to figure out what kind of variable I can use to persist a jobid across different users so they don't overwrite one another. I'm thinking session variables. But I'm so new at this I'm not sure if theres a better way?|||property? you aren't creating a new instance of the object, and sharing it between multiple calls? That's a bit unstable don't you think?|||Sometimes we learn those hard lessons through trial and error.|||I hear ya. :) I've done the same before actually.

this is OT, but hope it makes you feel better... two nights ago, I made a while loop with three nested loops and two methods. Two of the methods work with each other to determine the end of the loop. Let's just say I forgot to set the condition to false. :) Saw my ram go straight to 2gigs of usage from a single process.

And yeah, I've done some pretty interesting things that when looking back now.. I scoff at myself, but you're right, it's a live and learn ordeal.

Good luck in finishing.