Wednesday, March 28, 2012
PDF rendering problem if it is called from a modal page (fdf)
I am having this problem with rendering PDF. My modal is calling this report
page which renders the PDF by posting the parameter.
From a modal page.
//I have the parameters in the Form
var strReportPage = "frmReportModal.aspx";
formReport.action = strReportPage;
formReport.method = "post";
formReport.target = "blank";
formReport.submit();
The reportModal.aspx comes up with this error:
Adobe Reader could not open 'pa02528XX.fdf' because it is either not a
supported file type ... or because the file has been corrupted.
It will work fine if I try from a non-modal pagestrutt,
Unfortunately not at the moment. I don't if it is adobe problem.
"strutt" <strutt@.discussions.microsoft.com> wrote in message
news:6326B311-9604-434F-A92F-51618D7C38F8@.microsoft.com...
> Did you ever figure this out? I am having the same problem. It appears to
be
> something in Adobe, but I still don't have it fixed. Thanks for any help.
> "Hara" wrote:
> > Hi,
> >
> > I am having this problem with rendering PDF. My modal is calling this
report
> > page which renders the PDF by posting the parameter.
> >
> > From a modal page.
> > //I have the parameters in the Form
> > var strReportPage = "frmReportModal.aspx";
> > formReport.action = strReportPage;
> > formReport.method = "post";
> > formReport.target = "blank";
> > formReport.submit();
> >
> > The reportModal.aspx comes up with this error:
> >
> > Adobe Reader could not open 'pa02528XX.fdf' because it is either not a
> > supported file type ... or because the file has been corrupted.
> >
> > It will work fine if I try from a non-modal page
> >
> >|||Hara,
I did not figure out what was causing the problem either. I did come up with
a workaround though, If you change the content-disposition to
'attachment;filename=xxxxxx.pdf', then IE will prompt with a file open/save
dialog. If the user selects 'open'. the file opens properly in adobe reader.
Dave
"Hara Vilaythong" wrote:
> strutt,
> Unfortunately not at the moment. I don't if it is adobe problem.
>
> "strutt" <strutt@.discussions.microsoft.com> wrote in message
> news:6326B311-9604-434F-A92F-51618D7C38F8@.microsoft.com...
> > Did you ever figure this out? I am having the same problem. It appears to
> be
> > something in Adobe, but I still don't have it fixed. Thanks for any help.
> >
> > "Hara" wrote:
> >
> > > Hi,
> > >
> > > I am having this problem with rendering PDF. My modal is calling this
> report
> > > page which renders the PDF by posting the parameter.
> > >
> > > From a modal page.
> > > //I have the parameters in the Form
> > > var strReportPage = "frmReportModal.aspx";
> > > formReport.action = strReportPage;
> > > formReport.method = "post";
> > > formReport.target = "blank";
> > > formReport.submit();
> > >
> > > The reportModal.aspx comes up with this error:
> > >
> > > Adobe Reader could not open 'pa02528XX.fdf' because it is either not a
> > > supported file type ... or because the file has been corrupted.
> > >
> > > It will work fine if I try from a non-modal page
> > >
> > >
>
>
Tuesday, March 20, 2012
path not found when executing package using xp_cmdshell dtexec
I have a package that executes fine in BIDS. However, when calling it using xp_cmdshell it cannot find the path to the source flat file. Anyone have any suggestions?
Here is the statement:
xp_cmdshell 'dtexec /SQ NatlAcctsImport /SER CR1-SQL-01 /CONN SourceConnectionFlatFile;Q:\BI\NATNLACCTS'
Here is the result:
Microsoft (R) SQL Server Execute Package Utility
Version 9.00.1399.06 for 32-bit
Copyright (C) Microsoft Corp 1984-2005. All rights reserved.
NULL
Started: 9:50:56 AM
Progress: 2006-02-10 09:50:57.40
Source: Data Flow Task
Validating: 0% complete
End Progress
Progress: 2006-02-10 09:50:57.40
Source: Data Flow Task
Validating: 50% complete
End Progress
Progress: 2006-02-10 09:50:57.42
Source: Data Flow Task
Validating: 100% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Validating: 0% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Validating: 50% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Validating: 100% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Prepare for Execute: 0% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Prepare for Execute: 50% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Prepare for Execute: 100% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Pre-Execute: 0% complete
End Progress
Warning: 2006-02-10 09:50:57.43
Code: 0x80070003
Source: Data Flow Task Source - NATNLACCTS [1]
Description: The system cannot find the path specified.
End Warning
Error: 2006-02-10 09:50:57.43
Code: 0xC020200E
Source: Data Flow Task Source - NATNLACCTS [1]
Description: Cannot open the datafile "Q:\BI\NATNLACCTS".
End Error
Error: 2006-02-10 09:50:57.43
Code: 0xC004701A
Source: Data Flow Task DTS.Pipeline
Description: component "Source - NATNLACCTS" (1) failed the pre-execute phase and returned error code 0xC020200E.
End Error
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Pre-Execute: 50% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Cleanup: 0% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Cleanup: 50% complete
End Progress
Progress: 2006-02-10 09:50:57.43
Source: Data Flow Task
Cleanup: 100% complete
End Progress
DTExec: The package execution returned DTSER_FAILURE (1).
Started: 9:50:56 AM
Finished: 9:50:57 AM
Elapsed: 0.985 seconds
NULL
Since Q is likely a mapped drive then the problem is most likely that the mapping is not available when executed under xp_cmdshell. You could use a UNC path or, perhaps, have a task in the package create the mapping.
HTH,
Matt
|||I dont know if your Q: is a quorum drive or anything else, but of it is a mapped network drive I would rather use a UNC path than the mapped network drive letter. make sure that the SQl Server Service account has the appropiate right on the network share, otherwise you will run again in (permission) problems.
HTH, jens Suessmeyer.
|||changing the mapping to UNC path resolved the issue. thanks for the help!
Monday, February 20, 2012
Passing SELECTed rows to a calling SP
I'm a new T-SQL developer and just hit a roadblock.
I have a scenario that goes like this: I have 2 stored procedures,
spInner and spOuter. spInner has a SELECT statement which would
normally be used by a class using MS Enterprise Library and that output
goes into a DataSet. However, I need to get the output of the SELECT
statement to go into spOuter and that's what I can't seem to figure
out.
I know I may be asked to use functions that return tables in replies to
this post, but I can't do that as some parts of my application have an
EXEC(string) for dynamic SQL, instead of spInner.
Any help appreciated.
Cheers,
N.I.T.I.N.For the results of spInner to be available to spOuter, there are a few
options. I have used temporary tables or persisted the data into a real
table to avoid recompiles and also have a record of the data. If you use the
latter option, you can use a guid column and each row with a guid obtained
from spOuter. This way you can easily pick up the rows you need.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com|||NiTiN (emailme.nitin@.gmail.com) writes:
> I'm a new T-SQL developer and just hit a roadblock.
> I have a scenario that goes like this: I have 2 stored procedures,
> spInner and spOuter. spInner has a SELECT statement which would
> normally be used by a class using MS Enterprise Library and that output
> goes into a DataSet. However, I need to get the output of the SELECT
> statement to go into spOuter and that's what I can't seem to figure
> out.
> I know I may be asked to use functions that return tables in replies to
> this post, but I can't do that as some parts of my application have an
> EXEC(string) for dynamic SQL, instead of spInner.
I have an article on my web site that discusses possible options. See
http://www.sommarskog.se/share_data.html.
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx
Passing SELECTed rows to a calling SP
I'm a new T-SQL developer and just hit a roadblock.
I have a scenario that goes like this: I have 2 stored procedures,
spInner and spOuter. spInner has a SELECT statement which would
normally be used by a class using MS Enterprise Library and that output
goes into a DataSet. However, I need to get the output of the SELECT
statement to go into spOuter and that's what I can't seem to figure
out.
I know I may be asked to use functions that return tables in replies to
this post, but I can't do that as some parts of my application have an
EXEC(string) for dynamic SQL, instead of spInner.
Any help appreciated.
Cheers,
N.I.T.I.N.For the results of spInner to be available to spOuter, there are a few
options. I have used temporary tables or persisted the data into a real
table to avoid recompiles and also have a record of the data. If you use the
latter option, you can use a guid column and each row with a guid obtained
from spOuter. This way you can easily pick up the rows you need.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com|||NiTiN (emailme.nitin@.gmail.com) writes:
> I'm a new T-SQL developer and just hit a roadblock.
> I have a scenario that goes like this: I have 2 stored procedures,
> spInner and spOuter. spInner has a SELECT statement which would
> normally be used by a class using MS Enterprise Library and that output
> goes into a DataSet. However, I need to get the output of the SELECT
> statement to go into spOuter and that's what I can't seem to figure
> out.
> I know I may be asked to use functions that return tables in replies to
> this post, but I can't do that as some parts of my application have an
> EXEC(string) for dynamic SQL, instead of spInner.
I have an article on my web site that discusses possible options. See
http://www.sommarskog.se/share_data.html.
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Passing SELECTed rows to a calling SP
I'm a new T-SQL developer and just hit a roadblock.
I have a scenario that goes like this: I have 2 stored procedures,
spInner and spOuter. spInner has a SELECT statement which would
normally be used by a class using MS Enterprise Library and that output
goes into a DataSet. However, I need to get the output of the SELECT
statement to go into spOuter and that's what I can't seem to figure
out.
I know I may be asked to use functions that return tables in replies to
this post, but I can't do that as some parts of my application have an
EXEC(string) for dynamic SQL, instead of spInner.
Any help appreciated.
Cheers,
N.I.T.I.N.For the results of spInner to be available to spOuter, there are a few
options. I have used temporary tables or persisted the data into a real
table to avoid recompiles and also have a record of the data. If you use the
latter option, you can use a guid column and each row with a guid obtained
from spOuter. This way you can easily pick up the rows you need.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com|||NiTiN (emailme.nitin@.gmail.com) writes:
Quote:
Originally Posted by
I'm a new T-SQL developer and just hit a roadblock.
>
I have a scenario that goes like this: I have 2 stored procedures,
spInner and spOuter. spInner has a SELECT statement which would
normally be used by a class using MS Enterprise Library and that output
goes into a DataSet. However, I need to get the output of the SELECT
statement to go into spOuter and that's what I can't seem to figure
out.
>
I know I may be asked to use functions that return tables in replies to
this post, but I can't do that as some parts of my application have an
EXEC(string) for dynamic SQL, instead of spInner.
I have an article on my web site that discusses possible options. See
http://www.sommarskog.se/share_data.html.
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx