655 Posted Topics
Re: You also have a stray semicolon on line 7. Get rid of that and do as @KirstyHunter says, and it at least compiles and returns a result. The next obvious question is, what do you expect it to return? When I ran mine it returned a negative number. I can't … | |
Re: This assumes you are using SSMS 2008 or above. First, open a new query window, then type your query, specifying the NOCOUNT option: [CODE]SET NOCOUNT ON select * from #tmpRPLRouting where propertydatamap = '3' [/CODE] Then right-click and select Results To->Results To Text. Then, right-click and select Query Options... (down … | |
Re: VB, SQL, COBOL, C, C++, Java, Adabas/Natural, IDEAL, FORTRAN, Smalltalk, Actor, ObjectVision, 360 Assembler... Oh, wait...HUMAN languages? <dang> Maybe that's been my problem all these years...it's really hard to pick up chicks in COBOL... | |
Re: I saw this quite a few years ago...not my work but very clever...Asciimation version of Star Wars! http://www.asciimation.co.nz/ | |
Re: Or you could have a conversation with your employer and indicate you'd like to get some training or spend some time investigating a new innovative use of technology. Give them a chance to respond. I did that with my employer and I'm now happily coming up to speed on programming … | |
Re: You could also spend the time googling tutorial or forum sites for the technology of your choice, either to get insight into "best practices" or to learn something new. Another alternative is to actually avoid web-surfing and build some mini-projects of your own that might help you hone your own … | |
Re: Where to start? In your first statement, I assume you might be retrieving more than one row. So that means that you might have a non-EOF condition based on user-name. However, as you cycle through the rows, you might not get a match based on the additional criteria of YEAR … | |
Re: Q: How do you drown a "Hipster"? A: Throw him in the Mainstream! | |
Re: One of the greatest philosophical questions (in my humble opinion): "If is is is, is not is not is not?" Think about it... ;-) | |
Re: Anything having to do with "The Most Interesting Man In the World" (Dos Equis Beer), and the Old Spice ["I'm on a horse"](http://www.youtube.com/watch?v=VX5au0LOJp8) commercials (don't remember the name of the fellow in them). | |
Re: "TRUNCATE" is not a valid SQL statement for MS Access. It will work fine with MS SQL Server, though. For MSAccess you have to delete the rows with a DELETE statement. As a separate issue, you may also want to consider not using a recordset object for deleting all the … | |
Re: First off, your date criterion in your sample data is outside the bounds of the "BETWEEN". That's the most obvious thing. But that's not the real problem. Your problem is in all the "AND"s and "OR"s. If you think about it logically, what you are saying is that the ServiceCode … | |
Re: From the Platform SDK help file, Database and Messaging Services, Microsoft Data Access SDK, Microsoft ActiveX Data Objects, ADO Programmer's Reference, Error Codes: [QUOTE]adErrInvalidArgument 3001 0x800A0BB9 The application is using arguments that are of the wrong type, are out of acceptable range, or are in conflict with one another. adErrItemNotFound … | |
Re: There are a couple of ways to do it, depending on what version of SQL Server you are using and how detailed you need to get. First, in your query tool of choice (usually Management Studio) point to the database you're interested in, then use one of these: --for SQL2000 … | |
Re: I vote for infrared...especially during winter...help people out, stay toasty warm at the same time. :-) ![]() | |
Re: Not quite sure what you're asking for here. Do want the day of the week as a word (e.g. "Monday", "Thursday", etc.) or a day number (Sunday = 1, Monday = 2, etc.)? Day of the month? Anyway, the thing you should look into is the FORMAT statement. Here's a … | |
Re: There are several approaches you could take. It all depends if you want to exclude the rows before the load. Given the small proportion of rows to exclude, I would suggest you just go ahead and load the entire CSV into the database, then as a next step, join that … | |
Re: D - DON'T bother to show up...for a week. | |
Re: > Or just relax, go to the beach and watch the girls go by. ... > Android development is great, Or you could combine both of these activities and create FemBots like Dr. Evil from Austin Powers! :-) | |
Re: The problem is line 7. You're testing to see if there's a decimal point, then testing if there is a non-zero number after the decimal point...if there is, you return NULL. I'm not sure what you want to accomplish with that test...if you put in (for instance) 1234.0 then the … | |
Re: Since @id is a character column, you have to make sure that you have the requisite quotes surrounding it when the @sql variable gets populated. Your line 10 should look like this: SELECT @sql= 'select @total = count(*) from details where id='''+ @id + '''' The rest of it is … | |
Re: Okay, so you are probably not going to like this solution, but it will work. Please study it carefully because there are nuances in it, and I don't have time at the moment to walk you through it. If, after using this, you still have questions then please post them … | |
Re: Not quite sure what you're asking for here. What do you mean by "derived attribute"? If it is simply to derive an "AGE" column in a select statement, then you can just use the DATEDIFF function and specify the years between the DOB column and GetDate(). If you're looking for … | |
Re: In your "row.xml" file, change lines 25-26 and 32-33 from: android:layout_width="0dip" android:layout_height="fill_parent" to: android:layout_width="wrap_content" android:layout_height="wrap_content" I tested this and it seemed to work fine after that little change. | |
Re: So, is there an actual questions here? Some specific thing you're stuck on? Or are you just asking someone to build a report for you? If that's what you're expecting, I think you will be terribly disappointed. | |
Re: Seems that on the surface your problem doesn't sound like it should be giving you difficulties. Questions: 1. Is the combination of vSeries_Geography and vSeries_Type from the staging table enough to uniquely identify one row in the table tblVseriesList? 2. Is there a special reason you have created referential integrity … | |
Re: Break one of the candles in half, then break one of the halves in half again. You now have a quarter-candle. Now light the whole candle, burn it until it is the same size as the quarter-candle. This assumes, of course, that there are MATCHES in the room. Just sayin... … | |
Re: This one was kind of tricky, due to the limited amount of test data you supplied. The trickiness came in when you realize that any single item should only be counted ONCE, regardless of the number of times it gets transferred. Therefore (if I got this right) you might have … | |
Re: In order to use a derived table in MS SQL Server, you have to give the derived table an alias like so: -- // This is my update code insert into invoice select next value for inv_no_seq, company_id, convert(datetime, convert(date,getdate())), convert(datetime, convert(date,getdate())) + 30, amount from (select co.company_id ,sum(a.amount_paid) amount … | |
Re: To begin with, the test data you show for the "Group" table is wrong. I assume you meant that both CarID 2 and 3 were supposed to be in GroupID 2. Next is, if you're expecting to get the max price for a group, you have to leave out Car.Name … | |
Re: Questions like this are notoriously hard to solve because of two things: 1. The querent doesn't explain the situation fully or properly. 2. The querent doesn't explain the expected result fully or properly. So, for example, the original question contains the following line: >...one of the criteria is that a … | |
Re: You may wish to consider using different column names, because I believe at least two of your choices are reserved words in the MSAccess SQL dialect. As an alternative, you should enclose every column name (and probably the table name) in square brackets. This will force the Jet engine to … | |
Re: Besides, some of us like our anonymity...either that, or we aren't handsome devils like @happygeek! :-Þ | |
Re: >Are you trying to get answers to your own questions? I first came to DaniWeb trying to get answers. Then for a long time I almost exclusively contributed. I recently started doing Android development at the behest of my boss (damn his eyes!) so I'm once again looking for answers. … | |
Re: Is there an actual question here? It just looks like you're asking someone to do your homework for you. If you have tried to code something and are having trouble, post your code and your question and we will be happy to help. Otherwise, please do your own homework. | |
Re: Champions of Norrath. It just never gets old. | |
Re: No, the "Where" clause comes AFTER all the "JOIN" clauses. Your error is probably due to do with the fact that LB_No in the "where" clause is not fully qualified. It could be in any of the 5 tables, so you need to specify which one. Just a side note...putting … | |
Re: Prefixing the column name with the table name is to differentiate the columns in case both tables contain columns with the same name. For example, if I have two tables Students (student_id, last_name, first_name) Teachers (teacher_id, last_name, first_name) and I want to write a query showing all the students that … | |
Re: In some cases, it's just better to accept what's there and don't try to judge or try to figure out WHY they did what they did. Otherwise, we'd be second-guessing without the benefit of knowing what the situation was when it was written. Perhaps when it was written, there was … | |
Re: For MS SQL Server, you don't have to include the parens around the entire set of values for it to work. Your syntax should look like this: insert into myTable (col1, col2, col3, col4) values (1, 'a', 'v1', 23), (2, 'b', 'v2', 24), (3, 'c', 'v3', 25), (4, 'd', 'v4', … | |
Re: It would be good if you post the actual code you use. One thing to look at: how are you positioning your wildcard characters in your search? | |
Re: ...and herein lies the problem...YOUR one-word solution isn't the same as HIS one-word solution...and so you argue, and someone gets offended, and it escalates, and more people get offended, and someone else touches a match to that tinderbox, and BOOM. Sound like the entire history of the world? Yep, pretty … | |
![]() | Re: I'll listen to either Chopin piano music, Strauss waltzes or Beethoven's 6th symphony ("Pastorale"). That, or the White Stripes. :-) |
Re: There seems to be nothing wrong with your statement. I put together a tinkertoy version (based on a bunch of assumptions which may or may not be correct), and executed your statement on a SQL2008 instance and it seemed to work fine. So, it's impossible to help you unless you … | |
Re: From Dictionary.com: Ya·hoo /ˈyɑhu, ˈyeɪ-, yɑˈhu/ noun, plural Ya·hoos. 1. (in Swift's Gulliver's Travels ) one of a race of brutes, having the form and all the vices of humans, who are subject to the Houyhnhnms. 2. ( lowercase ) an uncultivated or boorish person; lout; philistine; yokel. 3. ( … | |
Re: Unless there is some relationship between the result sets for two queries you mention above, there is no way for SQL to decide how to return data. That's not what SQL is for. You could do this programmatically without too much trouble. You just have to instantiate two recordsets, then … | |
Re: This is treating the parenthesized "select" statement as a joinable table. So, assuming that the table EMPLOYEES has columns JOB_ID and SALARY, lines 5 and 6 specify the join criteria between the actual table EMPLOYEES and the derived table identified as "M". | |
Re: Try this: If KeyAscii = 13 Or KeyAscii = 9 Then surname_txt.Text = StrConv(surname_txt.Text, 1) + " | " fname_txt.SetFocus Exit Sub End If If KeyAscii <= 90 Or KeyAscii >= 65 Then surname_txt.Text = surname_txt.Text + " | " surname_txt.SelStart = Len(surname_txt.Text) End If Basically, every time you add … | |
Re: What have you already tried? Please post the SQL statement you've got, and we'll give it a look. Some sample data (suitably scrubbed, of course) would be helpful, as well as what you expect your result set to look like. Also, I notice there are quite a few foreign key … | |
Re: I was disappointed that it cut off before...well, I won't spoil it. :-) I can, however, see this thread becoming a "How many _________ does it take to change a lightbulb" joke collection.... |
The End.