Microsoft SQL Server 2005

71K

Solutions

26

Articles & Videos

25K

Contributors

Microsoft SQL Server 2005 is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning. It includes support for managing XML data and allows a database server to be exposed over web services using Tabular Data Stream (TDS) packets encapsulated within SOAP (protocol) requests.

Share tech news, updates, or what's on your mind.

Sign up to Post

Hello guys

I am having problem to do this, maybe the way is not correct and I don't have another idea how to achieve the task

take a look at the code:
with tab1 
as
( select numped, seqped, seq from arifat 
       where arifat.numped = 19315 
)
, tab2 as
(
  
  select * from dbo.Calculo_Tributos_Aux('FAT', 'P', '', tab1.numped, tab1.seqped, tab1.seq)  
)

select * from tab2

Open in new window



is it possible something like this?

I got this error:
Msg 102, Level 15, State 1, Line 10
Incorrect syntax near 'tab1'.

thanks
0
What Is Transaction Monitoring and who needs it?
LVL 1
What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Hi; How can i solve repeated value columns issue solve?  I have a query below, it is producing below table. But Batch and  ExpiryDate always repeated . they are the same in all rows. How can i rearrange below query?

SELECT k.*,k1.Batch FROM 
                            (
	                            SELECT 
	                             CONVERT(DATETIME, s.[ExpiryDate]) ExpiryDate
	                            ,s.[CustomerFullName]    
	                            ,s.[CustomerID]
	                            ,s.[MaterialName]
	                            ,s.[MaterialNumber]
	                            ,s.DeliveryDate
	                            ,s.SapContractNumber
	                            ,s.SapDeliveryNumber
	                            ,DATEDIFF(DAY, GETDATE(),s.ExpiryDate) DateDiff,
	                            s.PartType
	                            FROM [Sade].[dbo].[StokView] s 
                            WHERE  ( s.[ExpiryDate] BETWEEN @date1 AND @date2 )   @customer
                            )k
                            OUTER APPLY 
                            ( 
	                            SELECT di.Batch FROM dbo.DeliveryItems di WHERE di.SapContractNumber= k.SapContractNumber 
	                            AND PartType <> 'ReAgent'
                            )k1

Open in new window

image.png
0
Hi,

I have some users in my company that access our Production SQL instance via SSMS. I would like to know if there a way to block all domain users from using SQL Management Studio, except domain admin, as domain admin has 'sysadmin' rights.

We have software that utilizing Integrated Security.  I would still like our users to be able to utilizing our software using the SQL Windows authenticate, but not able to logon via SSMS.

Thanks!!
0
Hi,

I'm using SSRS designing a report which will show
two different dates only at any one time
comparing activity type and customer engagement.

so like this:

Activity Type           Date1                 Date2
Running                   100                    150
Cycling                      200                    150

Currently I hold these three values in a table and I use SSRS matrix to display these values like the above.
I am trying to figure out how I can add details against each of the dates to show a % difference on activity week over week.
I'm thinking perhaps this can't be done using SSRS matrix?
Maybe  I need to hard code the design and "calculation" column?

What I would like this to look like is
Activity Type           Date1                 Date2         %Diff
Running                   100                    150               + 50%
Cycling                      200                    150              - 25%

Can anyone give me some guidance on this. I have spent time looking online, but I'm not seeing anything that is working for me.
Thank you in advance
P
0
Error:
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
Verified that all services were started.
Named pipes were enabled.
TCPIP were allowed.
0
We just upgraded a server running Windows 2003 and MS SQL server 2005 to Windows 2008.  This upgraded the IIS from version 6 to 7.  We were running Windows authentication for the SQL database and we have a number of ASP pages that worked fine under IIS6, but crash with an error 500 under IIS7.  The website reads data fine from the SQL database when but when attempting to write to it, that's when the webpage crashes with an error 500 and in the W3SVC1 folder under C;\Windows\System32\Logfiles, the logfile shows under the lines where it tried to post, an error of 80070005 Access Denied.  I am thinking it's not passing the Windows credentials to the SQL database but it's only doing it for one of the tables.  On other tables, it writes the data to the table, but then bombs out the rest of the page and gives the error 500 on the webpage.  Do I need to rewrite the webpages to be compatible with IIS7 or is there a way to make IIS7 compatible with my webpages?  Any suggestions?

Thanks
0
Thank you all in advance!
We have column (cyclesec) that stores time values in terms of seconds an an nvarchar.
I need to be able to convert this value to  'time'. ideally in the following format.

mm:ss

In other words, the column (cyclesec) currently stores a value of 00:10:00 as an nvarchar.
I need to convert it, move it to a new column (minsecCycletime), and make it show up as a "time" as such:

10:00

Thank you all in advance!
0

Microsoft SQL Server 2005

71K

Solutions

26

Articles & Videos

25K

Contributors

Microsoft SQL Server 2005 is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning. It includes support for managing XML data and allows a database server to be exposed over web services using Tabular Data Stream (TDS) packets encapsulated within SOAP (protocol) requests.