I have a variable called @FilterCmd wher I am creating a query based on many different factors. The query is a select query. I tried running the query like so:
exec @FilterCmd
But I get an error. How can execute this?
How can I translate the following to its equivalent in TSQL?
IIF(CONVERT(age, int) < 18 AND ltrim(rtrim(age)) <> '', CONVERT(1, SQL_BIT), CONVERT(0, SQL_BIT)) AS IsJuvenile
I am writing an active report where I am trying to add 2 values from the database in the following way:
this.txtNumAddedTotal.Text = (this.Fields["intNewBPVRegistrations"].Value() + this.Fields["intNewBPVRegistrations"].Value());
But I'm getting an error stating...
I have been asked to create a report with the following look and feel grouped by type. How can I accomplish this grouping using Active reports? Also, if anyone knows where I can find a tutorial on Active reports I'd appreciate it.
Number Type Count1 Count2
2425 1...
I keep getting an error that states: "Operator '>' cannot be applied to operands of type 'string' and 'string'" when using the following. I'm trying to compare to see if the dtExpire date is greater than todays date. How can I do this in C#?
if(this.Fields["dtCertExpire"].Value.ToString() >...
I made a mistake. I meant to post the following query:
Select intTblID from tblMyTable
and
Select DISTINCT intTblID from tblMyTable.
Will the following work as well?
Select intTblID from tblMyTable Order By dtPrinted
I have the following query which will return 2 records (Each has different dtPrinted values but the same intTblID values):
Select intTblID * from tblMyTable
How can I modify the query below to return the record with the oldest dtPrinted value
Select DISTINCT intTblID * from tblMyTable
I'm trying to create a query I can use inside a DTS by dynamically setting the Query inside a dynamic properties task. Below is my select statement for creating the Select statement. I keep getting an error. It's mandatory that I use the query to load the values into the "IN" clause because...
Does anyone know if it's possible to pass in a query as a global parameter?
I tried adding a Dynamic Properties Task to set the global variable to the values I wanted posted inside the "IN" filter of the query but it never set the entire string to the value of the global variable.
I need to use a parameter to pass in one string with multiple values for use inside the "IN" filter of a select statement. Example: parameter is named myParam
I want to set myParam value to 'A2fg','A2fh','A2fi','A2fj'
And use it in the select statement inside the source query of a dts package...
I ended up clicking start/Run and pasted the following in "dtsrunui" and clicked OK. First select the server where your DTS packages is. This option is in the lower half, it says "Server". Then select the package name from the top button with the ellipse. Then click on Advanced. Type in the name...
I have a DTS package where I'm using a Global Variable in the where clause of the query for retrieving a record from the source. How can I call this from a sproc and pass in a value for the global variable?
Is there a way to use parellel processing to accomplish this? I have a linked server and running the following query times out:
Update dbo.TPSVCREQ
SET dbo.TPSVCREQ.ResultsFlag = 1,
--dbo.TPSVCREQ.ClientID = V.ClientID,
--dbo.TPSVCREQ.SolutionID = V.SolutionID,
dbo.TPSVCREQ.ResendFlag =...
You can try creating a DTS package if you are using SQL Server 2000 or SSIS in SQL Server 2005. Or you could create a linked server. The DTS and SSIS has better performance I believe.
I need to convert the following Access query to TSQL. The only problem is that I don't have any experience with a query like this. Any help is deeply appreciated.
(((IIf([tbl0000Tracking]![AvailableScanDate] Is Not Null,CStr(Format([tbl0000Tracking]![AvailableScanDate],"mm/dd/yyyy")),Null))...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.