I'll give you a 4 for that bad boy!
Shrimpersfan
Posts
-
When nothing goes right! (A joke - maybe not really) -
End of the world is nighDid someone say Elvis had died? Next you'll be telling me Michael Jackson has popped it!
-
database hellrurouniRonin wrote:
Be proud of being a VB dev
lol I'm only a junior and have only been developing for around 8-9 months, i don't believe i'm a fully fledged dev yet and have days where it seems i never will be lol. A very frustrating occupation at times! I've just started to get my head around CSLA which i think is a fairly easy framework to use.
-
Those bloody Meerkats!Possibly the most annoying advert on tv at the moment, along with that fat b*****d from GoCompare!
-
database hellWhat a bitch that i'm currently a junior VB developer lol! But seriously do you guys detest VB that much?
-
WPF Button BindingGood afternoon Wasn't sure if this should be in another section but couldn't find one for WPF so stuck it here. Here goes... I'm developing an application using MVVM. I need to save some info into a DB using the child_insert on my Model object. I have the button on my View and am wondering how I would bind this to my child_insert method, obviously you cannot bind a button to a method so would I need a command property on my VM and then bind to that? There is probably something quite simple I'm missing but I'm having a brain fart this afternoon and am at the stage of staring at my code with a blank expression. Thanks in advance.
-
Parameter problemsHi there. I have the following stored procedure: /**********************************************/ CREATE PROCEDURE sp_iet_ComplaintReport @StartDate DATETIME, @EndDate DATETIME AS select co.ComplaintID, pli.Description AS RegardingDD, co.DateRaised, c._accCustomercode, rtrim(c.firstnames) + ', ' + rtrim(c.lastnames) as Name, CASE WHEN co.BeenRead = 0 THEN 'Open' WHEN co.BeenRead = 1 THEN 'Completed' END AS Status, rtrim(u.fullname) as handler from complaint co inner join contact c on co.contactid = c.contactid inner join adm_picklistitem pli on co.regardingdd = pli.localcode and pli.picklistname = 'complaintlist' left outer join adm_user u on co.handler = u.userid where co.dateraised >= @startdate and co.dateraised <= @enddate GO /*********************************************/ This works fine but i want to be able to pass @Handler and map that to the complaint.Handler field. The thing that i want is if i pass NULL to the @Handler then it should bring back all Complaint.Handlers but if you pass an actual value to @Handler then this should bring back a matching value (if it exists). Sorry if I have worded poorly. Any help would be greatly appreciated.
-
UPDATE statement using a viewHi there I am trying to update a field in our contact table. I have a view which contains all of the contacts that i need to run the update for, my question is: How do i update a contact table but only update the contacts that are in my custom view?
-
Missing data recoveryThank you for all of your replies, it seems that I have lost all of the data and as you said I have learnt the hard way that we should keep on top of ALL our backups. Thankfully it shouldn't take too long to recreate the tasks, just means by busy couple of months just got a whole lot busier. Thanks again David
-
Missing data recoveryHi Bob How do you mean Audit table?
-
Missing data recoveryI am using a piece of automation software called Taskcentre, this has it's own database. This morning we were having issues with the software and it turns out that an essntial table has been cleared of all data. There are currently no backups for the database and all tasks that have been created over the past year are now gone unless i can find a way of restoring the database to 2 - 7 days ago. I was wondering if anyone had any ideas. David
-
SQL Insert Creates multiple records instead of just oneHi there, I have created an insert statement to create a new record in a database. This is used from a task automation program and the client record is mapped using that so records ARE created on the correct client but i only want 1 record to be created, at the moment if a client has 10 quotes then it will insert 10 new quotes instead of just 1. My code is below: CREATE PROCEDURE [dbo].[ietsp_CreateDODQuotes] @ContactID AS INT, @TaxYear AS INT AS SELECT @TaxYear = TaxProYear FROM FlightDeckTest.dbo.iet_TaxYears ty WHERE IsCurrent = 'T' /** Add PTM DOD Quote **/ BEGIN INSERT INTO FlightDeckTest.dbo.Lead ( ContactID, Owner, Status, EntitySubType, ietCreateDate, ietMumbaiStatus, ietTaxAdmin, ietTaxYear, ietQuoteIncl, ietQuoteExcl, ietVAT, ietProdServID, ietProdServDesc, ietPayMethod, ietCardType, ietCardHolder, ietCardNumber, ietAcctNo, ietSortCode, ietIssueNumber, ietSecurityCode, ietInstallments, ietMonthRepay, ietFinalWithIns, ietFinalInstallment, ietAcctName, ietBankName ) SELECT l.ContactID, l.Owner, 'AWAUTH', l.entitySubType, GETDATE(), 0, l.ietTaxAdmin, @TaxYear, l.ietQuoteIncl + CONVERT(DECIMAL(7,2),176.25), l.ietQuoteExcl, l.ietVAT, l.ietProdServID, 'PTM DOD - ie taxguard', 'INVTP', l.ietCardType, l.ietCardHolder, l.ietCardNumber, l.ietAcctNo, l.ietSortCode, l.ietIssueNumber, l.ietSecurityCode, l.ietInstallments, l.ietMonthRepay, l.ietFinalWithIns, l.ietFinalInstallment, l.ietAcctName, l.ietBankName FROM FlightdeckTest.dbo.Lead l INNER JOIN FlightDeckTest.dbo.Contact c ON l.ContactID = c.ContactID WHERE ((l.ietProdServDesc LIKE '%PTM%' OR l.ietProdServDesc LIKE '%Tax Return%')) AND (l.Status = 'ACT') AND (l.ietTaxYear IN (SELECT TaxProYear FROM iet_TaxYears WHERE IsCurrent = 'T')) END GO Any help would be greatly appreciated.
-
VB.NET SQL ErrorHi Rupesh. I seem to have sorted the problem. It seems as though a client had info missing in a completely seperate table. Thanks again. David
-
VB.NET SQL ErrorWell my app uses stored procedures to call up data, will be a lot of code
-
VB.NET SQL ErrorYes i tried different intervals, in the end i used 0 so the app should never time out. David
-
VB.NET SQL ErrorHi Rupesh. I have looked at the databases and looked for any NULL's in QuoteID but none appear. In my datagrid view, there is a white space below the last field (space to enter another record) but i shouldn't think the app will be trying to import a record from this. It's also strange how the import works with a smaller dataset but not with a large one. I have commandtimeout's in my code too. David
-
VB.NET SQL ErrorI have an application which uses a SQL connection and brings data into a datagridview. The app allows the user to take this data, make changes on it and then save these changes. This is fine when the user only brings back and manipulates around 100 - 1000 records, when the recordset is higher than this, all records that have been manipulated get inserted into the database apart from 1 record. The error message within the application says 'Cannot insert NULL value into column 'QuoteID', column does not insert NULL's. Insert failed. The app always brings back this error when using a large recordset, when i look in the db to see how many had been imported, every record is saved except one. Just wondering if anyone had come across something like this before.
-
Passing combo box values to datagrid viewI have an application which allows the user to select multiple combo boxes and then display data in a datagrid view depending on what is selected in the combo boxes. However, one of my fields is called 'Fee'. Obviously, this is a decimal value, I am trying to use a combo box to select a range of fees (0 - 150, 151 - 200 etc). For the other 3 combo boxes on the form, the values are coming from a stored procedure, however, i cannot do this for the 'fee' field because i receive errors when it tries to convert to decimal. The text in my combo box will be like the example above (0 - 150) but the values in the database are formatted differently (150.00, 170.20). My question is, how would i be able to filter out results in my datagrid view by using a range on the 'fee' field, i thought about a case statement but at the moment it just brings back a datagrid with 'rowerrors' as a column title.
-
VB.NET Filtering out datagrid data with combo boxHi there. I currently have an application where a user can select items from a combo box and then display the results in a datagrid view depending on what is selected in the combo box. This is fine because the user is selcting an exact match from what is in the sql connection but i need the user to be able to select a range from a different combo box, ie - if a field/row in the datagrid is 'Total' then i would want the user to be able to filter out all totals between '100 and 200' or '201 - 300' etc. I have tried using a case statement but am unsure if this is the right way of going about it.
-
Creating query from multiple combo boxesThanks Christian. I am aware of how to create string queries but what part of the form would i insert the query? Would it be the button that the user clicks when they have chosen what they want from the combo boxes? David