Sorry: Trying To Understand This Piece Of Code

Jul 20, 2005

I have this piece of script and I'm trying to understand what the
'SET t.Z_ASSOC_ROW = (t.rowid - m.MinRowID) + 1'
and the 'INNER JOIN' line is doing


UPDATE t
SET t.Z_ASSOC_ROW = (t.rowid - m.MinRowID) + 1
FROM tassoc t
INNER JOIN (SELECT Booking,MIN(rowid) AS 'MinRowID'
FROM tassoc
GROUP BY Booking) m
ON m.Booking = t.Booking



table 'tassoc'
rowid booking z_assoc_row
1 38 0
2 40 0
3 41 0
4 42 0
5 43 0
6 44 0
7 53 0
8 53 0
9 102 0
10 103 0
11 103 0

View 1 Replies


ADVERTISEMENT

Is This Piece Of Code Dangerous?

Jun 26, 2006

I'm building a site, and while stress testing it I received a few exceptions when the SQL Server was under relatively high load. Originally I was opening the connection when required in a particular Sub as follows (and then closing it when I was finished with it):
If Not MyConnection.State = ConnectionState.Open Then MyConnection.Open()
The probelm however was that from time to time the connection state was Opening instead of Closed or Open. So I am considering using the following piece of code instead:
            If MyConnection.State = ConnectionState.Connecting Then                Do Until MyConnection.State = ConnectionState.Open
                Loop            ElseIf MyConnection.State = ConnectionState.Broken Or MyConnection.State = ConnectionState.Closed Then                MyConnection.Open()            End If
I'm a little worried about the Do...Loop in there, but I don't see how it should be a problem. Any thoughts?

View 2 Replies View Related

What Is Wrong With This Piece Of Code?

Feb 7, 2007

select sub1.*, case sub1.mdiff when sub1.mdiff<12 then 1 else 0 end as flag

error msg by query analyser
Server: Msg 170, Level 15, State 1, Line 1
Line 1: Incorrect syntax near '<'.
Server: Msg 156, Level 15, State 1, Line 12
Incorrect syntax near the keyword 'as'.


Thanks

Jeff

View 2 Replies View Related

Exclude Piece Of Code From Transaction

Mar 20, 2008



Hello,

I have created a procedure with several SQL statement, all are included in a transaction.
Some of the code are "insert" in tables that are in remote server.
for example:


procedure sp1 is on SERVER B.
From SERVERA by linked server we have:

exec serverB.db_B.dbo.sp1 (from serverA the procedure sp1 is called)


CREATE procedures sp1
AS
BEGIN TRANSACTION
insert into T1 (col1) values (1)
insert into serverA.db_A.dbo.T2 (col1) vales ('8vhrfvrf')
insert into T3 (col1) values (3)
COMMIT TRANSACTION
GO


I would like to make that these piece of code (
insert into serverA.db_A.dbo.T2 (col1) vales ('8vhrfvrf')
) is out of transaction.
My question is: Is it possible to exclude piece of code from a transction?


You ask me why this: because SQL server do not allow loopback transaction


Thank

View 7 Replies View Related

SSMS Is A Piece Of....

Apr 2, 2008

Junk

OK, I have all of my SS2k sproc scripts saved as

owner.sprocname.prc

Because EM scripted them out that way

Now that we are using MS, it doesn't recognize the script, it doesn't highlight the code, and doesn't connect to a server

Can a change this somewhere?

I've got all of my scripts in pvcs as *.prc and I'd rather not have to change it

Any ideas?

View 5 Replies View Related

Selecting A Piece From A Colum

May 20, 2008

Hi All,
I have a column called TIER in my database which is a long string. There are piece of these strings that are separated by spaces like this:
'A3A00 A2B00 B1A00 C2C06 C3A06 C5A00 D2C00 G6B00 M2B00 M3B00 P7A00 T2A00 G4C00 G3C00 T5A06'
How do I select the last 2 characters of the piece of string when the first 2 chacters are M2?
I have the following:
This is retruning me all the rows that have 'M2'.
declare @code varchar (2)set @code = 'M2'select tier from companywhere tier like '%'+@code+'___ %'
 Any help is appreciated.
Thank you in advance.

View 3 Replies View Related

Display 1 Piece Of Data From A SQLDataSource

Jul 23, 2007

I have the following sqlDataSource. I wan't to display one piece of data, not a whole row, from it. I can find lots of information on putting it into a datagrid, but nothing on puttin one piece in a textbox. I cannot use a formview as we are embedding html in  response.write and it breaks in a formview. Thanks. 
 
<asp:SqlDataSource runat="server"
             ID="myEmpInfo"
SelectCommand="Select di.EmpInfo,di.eth,gc.t_level         From tblEmp di
        ,tblMisc gc
Where di.empnum = @empnumand di.empnum = gc.empnum" DataSourceMode="DataReader" ConnectionString="<%$ ConnectionStrings : myConnectionString %>">
 
<SelectParameters>
<asp:QueryStringParameter Name="empnum" QueryStringField="empnum"/>
</SelectParameters>
 
</asp:SqlDataSource>

View 1 Replies View Related

Compare 2 Piece Of String In A Column

May 30, 2008

Hi All,
I have a column in my table like so:
'D4B00 L2A00 L3A00 L6C00 P1C00 L2A28 P4B00 '
How do I check in SQL if any pieces have the first 3 character the same.  In the above case, L2A is present twice.  I need to do this because I need display disctinct items, therefore L2A needs to be displayed only once.
Any help is appreciated.
Thanks

View 3 Replies View Related

Change The Color On A Piece Of Text

Jun 1, 2007



Below is the pice of code that I use to produce results that look like this

[4] [5] [1]

what I would like to do is is make it look like this:

[4] [5] [1]

Basically anything that >3 = Green



= "[" & CStr(Count(IIf (Trim(Fields!NOB_Pickup_L_D_T.Value) = "Y", 1, Nothing))) &

"] [" & CStr(Count(IIf (Trim(Fields!NOB_Pickup_L_D_T.Value) = "N", 1, Nothing))) &

"] [" & CStr(Count(IIf (Trim(Fields!NOB_Pickup_L_D_T.Value) = "NA", 1, Nothing)))& "]"



Thanks,

Rick

View 3 Replies View Related

In The Pie Chart,how To Change The Color For Every Piece?

Jul 2, 2007

I work with .NET 2005.

thank you ...

View 6 Replies View Related

Read Single Piece Of Data From SqlDataSource To A Variable?

Jan 17, 2006

First I want to say thanks to the folks how have helped me over the past week or two.
I'm missing a crucial piece of insight. How do I read a single piece of data from a SqlDataSource which only hold one row of data into a declared variable?
string zUserName = SqlDataSource.(get the value in the row that is labeled UserName)
It really doesn't matter to me whether it is an SqlDataSource or some other data container that hold the data I've selected. My goal is to be able to read some data from some predefined datasource into a declared variable.
If I am approaching this problem in the wrong way any advice or article links you could give me would be grealy appreciate.
Thanks, Bill

View 1 Replies View Related

SQL Server 2012 :: How To Extract One More Piece Of Data From The Column

Dec 17, 2014

I have a database table that was designed by someone else, and I'm trying to see if I can normalize the pattern. Here's the dummy table:

CREATE TABLE [dbo].[BadTox](
[PatientID] [int] NULL,
[Cycle] [tinyint] NULL,
[ALOPECIA] [tinyint] NULL,
[Causality1] [tinyint] NULL,

[Code] ....

All the column names in upper case are actually symptom names, and in those columns are values {NULL, 1, 2, 3, 4, 5} and they belong in a column, so the normalized structure should be like this:

CREATE TABLE Symptom (
PatientID INT NOT NULL,
Cycle TINYINT NOT NULL,
SymptomName VARCHAR(20) NOT NULL, -- from the source column *name*
Grade TINYINT NOT NULL -- from the value in the column with the name in uppercase
PRIMARY KEY (PatientID, Cycle, SymptomName));

I can untwist the repeating groups with the code I borrowed from Kenneth Fisher's article [ here ], but the part I'm having a harder time with is grabbing the information that's still left in the column name and integrating it into the solution...

I can retrieve all the column names that are in uppercase using this:

DECLARE @db_id int;
DECLARE @object_id int;
SET @db_id = DB_ID(N'SCRIDB');
SET @object_id = OBJECT_ID(N'SCRIDB.dbo.BadTox');
SELECT name AS column_name
, column_id AS col_order
FROM sys.all_columns
WHERE name = UPPER(name) COLLATE SQL_Latin1_General_CP1_CS_AS
AND object_id = @object_id;

but I can't figure out how to work it into this (that I built by mimicking Kenneth Fisher's article...):

ALTER PROC [dbo].[UnpivotMaxGradeUsingCrossApply]
AS
SELECT PatientID
, Toxicity
, MAX(Grade) AS MaxGrade

[code]....

The problem is that I need to extract the column names (where ToxicityName[n] would be). I can do that by querying the sys.all_columns view, but I can't figure out how to integrate the two pieces. About the only thing I have even dreamed up is to build the VALUES(...) statements dynamically from the values returned by the system view.

So how do I get both the value from the ToxicityName[n] column and the column name into my final data query?

View 5 Replies View Related

Transact SQL :: REPLACE Part Of String With Different Piece Of Text

Apr 20, 2015

I have a string column in a DB where it's values contain the following midway through the string ([DOCUMENTGUID] is a uniqueidentifier that is different for each row):

<a href="../downloadDoc.aspx?dg=[DOCUMENTGUID]" target="_blank">

I would like to replace this part of the string with a different piece of text.

I know that I should be using PATINDEX and REPLACE functions but I don't know how to utilise.

View 4 Replies View Related

Retrieving A Piece Of Datalogged Equipment By Most Recent Time

Jun 22, 2006

The TSQL below all works except the bolded part at the end. I'm want to grab only the most recently logged piece of equipment not the most recent and all past ones as well which is what I've got doing minus the bolded part below. But I don't know how to say get this Equipment ID etc and only the most recently logged one to find its present location. The bolded part below is just there to show what I want it to do I know you can use an aggregate in a where clause. So in the first table listed tblRdrLog there is a column Time that I want to do this on so a.Time. I don't want to display a.Time just reference.

String dbsql = " SELECT a.EquipmentID " +
" , f.Subcategory " +
" , c.Area " +
" , d.Room " +
" FROM tblRdrLog a " +
" JOIN tblRdrInfo b ON a.ReaderID = b.ReaderID " +
" JOIN tblRdrArea c ON b.AreaID = c.AreaID " +
" JOIN tblRdrRm d ON b.RoomID = d.RoomID " +
" JOIN tblEquipInfo e ON a.EquipmentID = e.EquipmentID " +
" JOIN tblEquipSubcat f ON e.SubcategoryID = f.SubcategoryID " +
" WHERE a.EquipmentID IN (SELECT a.EquipmentID " +
" FROM tblEquipInfo a " +
" JOIN tblEquipCat b ON a.CategoryID = b.CategoryID " +
" JOIN tblEquipSubcat c ON a.SubcategoryID = c.SubcategoryID " +
" LEFT OUTER JOIN tblEquipMake d ON a.MakeID = d.MakeID " +
" LEFT OUTER JOIN tblEquipModel e ON a.ModelID = e.ModelID " +
" JOIN tblStatus f ON a.StatusID = f.StatusID " +
" WHERE b.CategoryID = '" + this.ddlCategory.SelectedValue.ToString() + "' ";

if (!"".Equals(this.ddlSubcategory.SelectedValue.ToString()))
dbsql += " AND c.SubcategoryID = '" + this.ddlSubcategory.SelectedValue.ToString() + "' ";

#region Advanced Search Criteria

// Check whether advanced search submitted
if (adv)
{
if (!"".Equals(this.tbSerialNo.Text.ToString()))
dbsql += " AND a.SerialNo = '" + this.tbSerialNo.Text.ToString() + "' ";
if (!"".Equals(this.ddlMake.SelectedValue.ToString()))
dbsql += " AND d.MakeID = '" + this.ddlMake.SelectedValue.ToString() + "' ";
if (!"".Equals(this.ddlModel.SelectedValue.ToString()))
dbsql += " AND e.ModelID = '" + this.ddlModel.SelectedValue.ToString() + "' ";
if (!"".Equals(this.ddlStatus.SelectedValue.ToString()))
dbsql += " AND f.StatusID = '" + this.ddlStatus.SelectedValue.ToString() + "' ";
}

#endregion

dbsql += " ) " +
" AND a.Time = max(a.Time) " +
"";

View 11 Replies View Related

Hm...can`t Understand, Please Help

Dec 27, 2004

i have this situations:

the aspx file with source code work good.
when i try run project which created from VS i take
"SQL Server does not exist or access denied."
connection strings same:

"Data Source=**.**.**.**,1433;Network Library=DBMSSOCN;Initial Catalog=slider;User ID=username;Password=password;"

i think may be it`s web.config in project wrong?

Edited by SomeNewKid
Removed username and password from connection string.

View 1 Replies View Related

Don't Understand

Aug 27, 2006

I am having a problem reinstall SQL Express 2005.  I had it installed, but then I unistalled it.  I have tried installing it again, but everytime I do it says that the product is already installed.  There is no instance of it in my Add/Remove Programs.  I have read the threads that relate to this topic, but they haven't helped.  I have looked at my logs of the installs, but they don't make sense neither.  I just want the program installed again, or a way to get it so that I can use it. 

When I try to manually uninstall using msiexec.exe /x <processid> I get an error saying that the package could not be opened.  This happens with all the process ids I use that I get from the log files (I have 11 logs).

 am using Visual Basic 2005 and trying to create a database, and it will not let me.  That is how I know that it is not installed, plus I can't find any instance of it one my computer.  Please help.  Thanks.

View 8 Replies View Related

I Need To Understand

Nov 19, 2006

How di I understand what SQL Server Integration Services mean? Can some one help me?

View 3 Replies View Related

Isn't Working... I Don't Understand?

Feb 23, 2008

I'm trying to put together a very simple page where you can click the up and down button to move the item up or down in the list and save the new list into the database. I've run the stored procedure... and it works so Its not a procedure problem. Here is the list in my databaseOrder_Id        Item         Position1                  Sebring     12                  GrandPrix  23                  Accord      44                  Miati         3 When I go to click the button I get a object reference not set to an instance of an object... This error haunts me many times. Heres the code to my project:BLL  /// <summary>
/// Gets Items from the Item table.
/// </summary>
/// <returns>A list of items.</returns>
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Select, true)]
public OrderItemDataSet.OrderItemDataTable GetItemDataByPosition()
{
return OrderItemAdapter.GetItemDataByPosition();
}

/// <summary>
/// Gets the order id based on the position specified.
/// </summary>
/// <returns>The order id.</returns>
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Select, true)]
public int SelectOrderIdByPos(int pos)
{
return SelectOrderIdByPos(pos);
}

/// <summary>
/// Update Order list.
/// </summary>
/// <param name="newPos">Position to change to.</param>
/// <param name="originalPos">Original position.</param>
/// <param name="orderId">Original id.</param>
/// <param name="otherOrderId">Position to change id.</param>
/// <returns></returns>
[System.ComponentModel.DataObjectMethodAttribute(System.ComponentModel.DataObjectMethodType.Update, true)]
public void ReorderItemByIdAndPosition(int newPos, int originalPos, int orderId, int otherOrderId)
{
OrderItemAdapter.ReorderItemByIdAndPosition(newPos, originalPos, orderId, otherOrderId);
}   Codebehind  1 using ReorderListWebApplication.BLL;
2 using System;
3 using System.Collections;
4 using System.Configuration;
5 using System.Data;
6 using System.Linq;
7 using System.Web;
8 using System.Web.Security;
9 using System.Web.UI;
10 using System.Web.UI.HtmlControls;
11 using System.Web.UI.WebControls;
12 using System.Web.UI.WebControls.WebParts;
13 using System.Xml.Linq;
14
15 namespace ReorderListWebApplication
16 {
17 public partial class _Default : System.Web.UI.Page
18 {
19 protected void Page_Load(object sender, EventArgs e)
20 {
21
22 }
23
24 protected void UpButton_OnClick(object sender, EventArgs e)
25 {
26 Label posLabel = (Label)ReorderItemDataList.FindControl("PosLabel");
27 Label idLabel = (Label)ReorderItemDataList.FindControl("IdLabel");
28
29 using (ReorderListWebApplication.BLL.OrderItem item = new ReorderListWebApplication.BLL.OrderItem())
30 {
31 int pos = 0;
32
33 pos = item.SelectOrderIdByPos(Convert.ToInt32(idLabel.Text) - 1);
34
35 // Grab other orderId!!
36 item.ReorderItemByIdAndPosition((Convert.ToInt32(posLabel.Text) - 1), Convert.ToInt32(posLabel.Text), 3, pos);
37 }
38 }
39
40 protected void DownButton_OnClick(object sender, EventArgs e)
41 {
42 using (ReorderListWebApplication.BLL.OrderItem item = new ReorderListWebApplication.BLL.OrderItem())
43 {
44
45 }
46 }
47 }
48 }
49
 

View 8 Replies View Related

I Don't Understand The Following Error....

May 2, 2008

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.InvalidOperationException: You have specified that your update command compares all values on SqlDataSource 'SqlDataSource5', but the dictionary passed in for oldValues is empty.  Pass in a valid dictionary for update or change your mode to OverwriteChanges.
can somebody tell me what this is?
Angiemarie

View 3 Replies View Related

Don't Understand This Error

Oct 18, 2005

Hello, I could use some help with this error message:
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
This if statement is the problem
IF (select bill_freq from #header1) = '1'   update #header1 Set     [Monthend] =  aa.pername    from sv00564 zz inner join sv00532 aa on zz.wennsoft_period_id = aa.wennsoft_period_id   Where zz.rmdnumwk like #header1.Invoice_Number

View 1 Replies View Related

Don't Understand Error...

May 4, 2006

This is failing:// Trying to update DynamicPageContent.Html where DynamicPageContent.PageID='121'//With// Select Html from DynamicPageHistory where HistoryID='831'//Update DynamicPageContentSET Html=(SELECT Html FROM DynamicPageHistory WHERE HistoryID='831')WHERE PageID='121'With the following error:Server: Msg 279, Level 16, State 3, Line 1The text, ntext, and image data types are invalid in this subquery or aggregate expression.DynamicPageContent.Html is Ntext size 16 and DynamicPageHistory.Html is Ntext size 16. PageID is and int and HistoryID is an int. It fails with single quotes around 831 and 121 and it fails without single quotes. The error message is the same both ways.Ideas?Thanks,Rex

View 4 Replies View Related

Starting To Understand

Jun 29, 2004

I feel extremly happy today and let me share with this wonderful forum why.

SQL is awesome and I'm really learning that theres alot of resources out there and coding is not that hard once you understand what your doing. Just took awhile for things to sink in. I still have a long ways to go but I'm really enjoying using sql. I practically live in our SQL Server 2000 at work and I'm learning more and more about it everyday.

Thank YOu so much guys I really appreciate all the help you've given me
Now I'm gonna study for the sql cert

:)

View 3 Replies View Related

Don't Understand GROUP BY...

Mar 8, 2005

I have a table Test_GUID, with fields id as int PK IDENTITY, GUID as varchar(50), and Version as tinyint. I put data in it such as

id GUID Version
------------------
1 abc 1
2 abc 2
3 def 1


Then I tried to get the following result:

id GUID Version
-------------------
1 abc 2
3 def 1

By using a query:

SELECT GUID, MAX(Version) AS MaxVersion, id
FROM dbo.Test_GUID
GROUP BY GUID

But then I get an error because id is not being aggregated.

This works

SELECT GUID, MAX(Version) AS MaxVersion
FROM dbo.Test_GUID
GROUP BY GUID

but then how do I get the id of each record?

View 2 Replies View Related

Help Me To Understand This SQL Sentence

Jul 18, 2006

Set @mSQL = 'SELECT Max([AccountID] + [ItemID] + [StorehouseID] + [BINID] + [LotItemID] + Convert(varchar(10),[BalDate],111)) AS [KEY],
AccountID, ItemID, StorehouseID, BINID, LotItemID INTO [xIV_tblStockSumLastDate' + ']
FROM IV_tblIVMaster
WHERE (BalDate<= 'Exec(@mSQL + '''' + @mtxtDate + '''' + ')
GROUP BY ItemID, AccountID, StorehouseID, BINID, LotItemID')

View 13 Replies View Related

Don't Understand The Error.

Oct 18, 2006

I'm doing code with VB.Net.

The error was:
System.FormatException: Input string was not in a correct format.


The line this is happening on is:
Response.Write("<TD><p>" + rdData("ClientRepID") + "</p></td>")


I don't understand, it is giving that error particularly when I want to get ClientRepID

Some more lines from the code:
Response.Write("<TD><p>" + rdData("Username") + "</p></TD>")
Response.Write("<TD><p>" + rdData("ClientRepID") + "</p></td>")

The first line the compiler had no problem but when it gets to the second line with ClientRepID it gives me this error. (ClientRepID exists in the database)

Can someone please help me? Thanks

View 4 Replies View Related

I Don't Understand Licencing

Apr 19, 2007

Hello, i just bought sql server 2005 with 5 cals (previously i was using a shared sql server with my previous host)... I probably should have asked this question before i bought it... i don't understand how the cal licencing works... the sql server is for running our ecommerce site, i just got a dedicated server to put this on... but from reading the licencing does this mean that only 5 internet users can access my website(or the information in the database) at a time???

any help with this would be appreciated

~ Moe

View 4 Replies View Related

I Don't Understand Quoted_identifier

Mar 24, 2008

OK, so I know that following works if I want update/insert the value "joe's bar" into the table.


set SET QUOTED_IDENTIFIER on
update #temp set id=4 where name ='joe''s bar'


The thing is, I do not conceptually understand what is happening and it is driving me nuts. I have read and re-read the description of quoted_identifier in books online and I still don't get it. How does the extra ' after joe make it work? Is there any hope for me? :)

View 4 Replies View Related

Trying To Understand Triggers

Jul 23, 2005

Hi,Newbie here. I have a mailing list program that I really like. I also have anew membership program. The membership program has mailing list signupsbuilt-in, but it isn't nearly as robust as the stand-alone mail program.If someone signs up for a newsletter when they register (membershipprogram), can a "trigger" in SQL Server put the same information into thestand-alone program's tables? And when they remove or update theirlists/info? And vice-versa?Is this what a "trigger" would do? And is it efficient?Thanks,JA

View 2 Replies View Related

SQL Backup - Dun Understand

Nov 23, 2005

Hi ,I am running SQL server 2000 sp3a and i have set up my database to be in"Full Recovery" mode.I am not able to understand if i have set anything wrong here :1. Full database Backup - every weekend2. Differential Backup - twice a day3. Txn log backup - 4 times a day (4hrs apart)Situation :my Txn Log file is now 18GB ,i can see it's only taking up around 1.5 GB ofactual space usedQues :i thought after every full database backup on each weekend, the txn logbackup will clear up the txn log , if so i see no reason why the txn log cangrow to 18 GB unless between the txn log backup , there's alot of data comingin that caused the txn log to grow but this is not the casekindly advise if my setup is wrong or what could have happened somwhere tocause the log to grow so muchtks & rdgs--Message posted via SQLMonster.comhttp://www.sqlmonster.com/Uwe/Forum...eneral/200511/1

View 2 Replies View Related

Primary Key: I Am Trying To Understand--please Help If You Can.

Jul 20, 2005

Hi all,So I've been reading the newsgroups, and reading a few books trying to learnSQL and SQL Server 2000. The books tell me I need a Primary Key, and thatevery table should have one. I know (I think) that a Primary Key is aspecial field that uniquely identifies each record or row within a table.My question is this: If I have a field or column whose values are all (andwill be) different in every row, is that what a Primary Key is, or is it nota primary key until I designate it as such with either a statement or byright-clicking a little key on the table diagram.If so, then what is the reason _behind_ why I have to do that, and have aprimary key?I've been playing with a few tables, and I can select information just fine,relate tables together with joins, and everything works fine (so far) allwithout my designating any Primary Keys--so why, exactly, do I need one, andexactly what is it?I would appreciate any help and clarification.Thanks.

View 4 Replies View Related

I Don´t Understand

Jun 23, 2006

i´m sorry my bad english

i have a dts in sql server 2005

for example in sql server 2000 i can do that :

over DTS right-clik choose option "Scheduled pachage" and this create a scheduled what i mean is that this produces a "JOB"

what i mean is that i need to know how can to create a scheduled to DTS´s in sql 2005

Please anyone of you provide some solution for this.

View 13 Replies View Related

Help With An Error I Don't Understand

Aug 31, 2007

Hey everyone,

I'm trying to make an image appear differently depending on the values of certain data. The statement that I am using is:

= IIF(DATEDIFF("dd",Fields!LastBackupDate.Value,Now)>15,"redball",IIF(DATEDIFF("dd",Fields!LastBackupDate.Value,Now)<8,"greenball","yellowball"))

And the error that I get is:


[rsRuntimeErrorInExpression] The Value expression for the image €˜image4€™ contains an error: Argument 'Interval' is not a valid value.

Preview complete -- 0 errors, 1 warnings

When I preview the report I just get the typical white box with a red x where the image should be. I don't understand.

Thanks in advance,
Keith

View 1 Replies View Related

Get Last Record, Of Many... Read To Understand

Mar 13, 2008

Ok,
I have a table with the following fields:
ID, Type, Name, Date, Description
ID is the PK. Names all have different values, but are predefined... a visual:
ID, Type, Name, Date, Description
1, monday, mon1234,3-3-08, some text
2, monday, mon1234,3-4-08, some text
3, monday, mon2345, 3-5-08, some text
4, monday, mon2345, 3-6-08, some text
 Now What i need to do is get the last report for each unique "Name". How would I do that?
When I try to do a Select Distinct, of course, it only gives me those names that only appear once.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved