How can I set this into a declared variable so I can use this in an IN Statement
DELCARE @CustList AS varchar(50)
SET @CustList = '1','2','3','4'
SELECT * from tblCustomer where CustNumb IN (@CustList)
Hello all. When Selecting from the Inserted table on a trigger wont there always be just one record?
UPDATE Customer Set MailSend = 1 where CustNumb =
(SELECT CustNumb FROM INSERTED)
This is on the insert of a new record. Wont I only have one value for this each time? Somehow I am...
Hello all. I have 12 textboxes on a form where currently I have a client control validator for each checking if the value is currency. How can I also call a sub routine either on the change or exit of the textbox to call a Total Sub Routine which adds up the textboxes and places it into a...
I need to total textboxes going across. However I do not want to place a "0" in the textbox itself. Can I somehow default in my code that value to 0 without having to complete IF statements. Right now it goes (Cdbl(textbox1.text) + CDbl(textbox2.text).ToString
But one of the values could be...
I have a datagrid where I have a "DataFormatString="{0:#,##0.00}" as the format of the column. I am using CDbl to total columns with a .ToString at the end to fill a textbox. How can I make this the same format so lets say 10000 comes up 10000.00 thanks all.
Hello all. I have multiple text boxes that are going to have the user typing in currency values like 5.25. How can I have one validator to handle these multiple textboxes? I don't want to have to use a validator control for each textbox. Thanks all
Hello all. I am trying to recreate an access query in SQL. The query below where you see the HAVING clause is causing less records to come out then without it, however there is no Null values in that table "Bud_State Allocation" that is referenced in the Having clause but its still returning...
Hello all how do I do this.
- I have 2 fields 1 called ScanName and 1 called ScanOrderName
- I have 2 values that can be vice versa in these fields like so:
Value 1: B Barker
Value 2: Bob Barker
I want to somehow wild card search and flag a partial match. In this case it would be a...
Ok this might be totally confusing but I am giving it a shot because I am completly confused right now on this and need help. I have a large query that is using a Cross Join in it. Here is the basic part of it.
----------------------------------------------
MAIN QUERY called CC1.
CROSS JOIN...
Hello all. In a proc what is the best way to handle this. I have a parameter getting passed in called @PageName
I need to check if this name exists in a table I have. If it does not then I want to INSERT a record. I know I can handle it this way below but I think this must be a better way...
Hello all. Here is what I want to try to do. I have a folder on my C Drive where I have a bunch of PDF files. I then have a SQL table with records that have the path to these files. I need to clean up the folder and delete any files in the directory that do not have a record in the SQL...
Hello all. One more question for the day. I have some temp tables I need to create but they would be used in more than one proc. If I run a Proc that creates the temp tables within another proc I wont have scope of those temp tables that are created from the proc called correct? Is there a...
Hello all. I am running into an issue with a query I have. I have a query that takes 2 seconds to run it flies and returns a result set. There are 2 fields in the result set that I need to say "WHERE Field1 = Field2". However, it is totally hanging the query up and it runs forever. How can...
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.